Hello,
I have to apologize because I've fooled myself. Everything works fine in
the Haskell side.
The problem was that I tried to pass a float value to printf which is a
variadic C function.
According to the C standard / stack overflow:
> * because printf and its friends are variadic functions, s
I added Stg and Cmm linter to my custom pipeline and they report no errors.
On Wed, Jan 22, 2020 at 4:40 PM Csaba Hruska wrote:
> Here are the pretty printed STG in GHC syntax:
>
> *WORKING (DoubleRep): prints 3.14*
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
> *x0 :: Any[GblId] ="Value: MyConA %d %d\
Here are the pretty printed STG in GHC syntax:
*WORKING (DoubleRep): prints 3.14*
*x0 :: Any[GblId] ="Value: MyConA %d %d\n"#;x1 :: Any[GblId] =
"Value: MyConB %lf\n"#;main :: Any[GblId] =[] \u [void_0E]case
MyConB [3.14##] of x100 { __DEFAULT ->
Sorry, I should have noted that the gist has a description comment at the
bottom.
https://gist.github.com/csabahruska/e9e143390c863f7b10b0298a7ae80ac1#gistcomment-3148797
On Wed, Jan 22, 2020 at 3:21 PM Ömer Sinan Ağacan
wrote:
> What is the problem you're having? What do you mean by "run into
What is the problem you're having? What do you mean by "run into problems"?
What's going wrong?
It'd be helpful if you could show us your program in STG syntax.
> Is it valid to use FloatRep argument in a boxed ADT on 64 bit?
It should be valid, yes.
I'd also try with `-dstg-lint -dcmm-lint`.
Hello,
I try to use GHC backend via STG. For that reason I build small STG program
AST maually. So far the generated programs worked fine (compile/link/run).
However I run into problems when a lifted ADT has a FloatRep argument.
Interestingly it works for DoubleRep.
I'm using GHC 8.6.1 64 bit to g