[commit: ghc] master: include FastString.string_table in CoreMonad.reinitializeGlobals (163de25)

Nicolas Frisby nicolas.frisby at gmail.com
Fri Jul 5 02:54:01 CEST 2013


I'm validating Option 2 at the moment. It works if the plugins force the
FastStrings before returning to the host compiler. However, robustness
would require that each of the plugin's passes also call
reinitializeGlobals, since some FastStrings may have been allocated between
the installation of the plugin and its passes.


On Thu, Jul 4, 2013 at 12:26 PM, Nicolas Frisby <nicolas.frisby at gmail.com>wrote:

> On Thu, Jul 4, 2013 at 2:52 AM, Simon Peyton-Jones <simonpj at microsoft.com>wrote:
>
>> Do you put the FS table back after running the plugin? If not, the same
>> unique may be allocated more than once.
>>
>> S
>>
>
> No, I did not do that. And writing this email, I realized my initial
> reasoning was flawed. There are some decisions to be made.
>
> I've written it up here. Feel free to skip Option 1; I think it has the
> least merit.
>
> http://hackage.haskell.org/trac/ghc/wiki/Plugins/ReinitializeGlobals
>
> I'd appreciate if people could weigh in.
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/ghc-devs/attachments/20130704/ee5e827f/attachment.htm>


More information about the ghc-devs mailing list