Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GHC-generated LINE annotation might cause non-deterministic build #105

Open
cartazio opened this issue May 16, 2017 · 4 comments
Open

GHC-generated LINE annotation might cause non-deterministic build #105

cartazio opened this issue May 16, 2017 · 4 comments
Labels
info needed More information (like MWE) is needed (e.g. from reporter) LINE annotations Concerning LINE annotations in the generated file output formatting Conerning the layout of the generated files upstream Problem needs to be fixed upstream (GHC, dependencies, ...)

Comments

@cartazio
Copy link

AlexWrapper-basic copy.txt

theres thousands of newlines in that attached file!
also some of the source / line attributions seem likely to cause nondeterminstic builds under some conditions
eg


{-# LINE 1 "/var/folders/py/wgp_hj9d2rl3cx48yym_ynj00000gn/T/ghc64947_0/ghc_2.h" #-}

cc @hvr

@erikd
Copy link
Member

erikd commented May 16, 2017

I agree that it would probably be nice to remove excessive newlines, but I can't see how these, or the source line attributions could cause non-deterministic builds. Can you generate a test case that show this?

@erikd
Copy link
Member

erikd commented May 16, 2017

Ok so the non-determinacy comes from things like:

{-# LINE 1 "/var/folders/py/wgp_hj9d2rl3cx48yym_ynj00000gn/T/ghc64947_0/ghc_2.h" #-}

but does that come from Alex or GHC ?

@hvr
Copy link
Member

hvr commented May 16, 2017

That looks a lot like a tmp-file generated by GHC... I wonder if GHC should #line-annotate positions in ephemeral tmp files... (especially if -keep-tmp-files is not active)

@andreasabel andreasabel added discussion LINE annotations Concerning LINE annotations in the generated file output formatting Conerning the layout of the generated files upstream Problem needs to be fixed upstream (GHC, dependencies, ...) labels Jan 25, 2022
@andreasabel andreasabel changed the title bizarre amount of newlines in generated templates GHC-generated LINE annotation might cause non-deterministic build Jan 25, 2022
@andreasabel andreasabel added info needed More information (like MWE) is needed (e.g. from reporter) and removed discussion labels Jan 25, 2022
@andreasabel
Copy link
Member

Is this still a problem? Cannot reproduce atm.
We need a reproducer to report this upstream.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
info needed More information (like MWE) is needed (e.g. from reporter) LINE annotations Concerning LINE annotations in the generated file output formatting Conerning the layout of the generated files upstream Problem needs to be fixed upstream (GHC, dependencies, ...)
Projects
None yet
Development

No branches or pull requests

4 participants