It should be fine if updated when visiting statements. I am not worried about performance issue as this is just a simple copy... But I'm wondering why would it take 17.3s to compile a file with 10k…
Yes, add expected type to get_symbol_value
is fine IMO.
I wonder if we should add current_loc
to CodeGenContext
. You can pass the location information when you call functions like list assignment, so this change is really not necessary. The problem with this is that the location information is only updated when we visit Expr
nodes, but not updated for other nodes such as statements.
I guess we should change the powi.f64.i16
to powi.f64.i32
to fix this bug. Not sure if this can be considered as a bug in LLVM because they said
the only supported type for the exponent is…
Interestingly this works:
define void @test() {
body:
%f_pow_i = call double @llvm.powi.f64(double 2.000000e+00, i32 -2)
call void @output_float(double %f_pow_i)
ret…
what are the unoptimized and optimized IRs for this code prior to this patch?
Might be good to have tests for this kind of thing that look at the IR.
Yes, we can see if there is a call void @print_int32(i32 123)
. We should not match the entire IR as it is too brittle.
if constructed via constructor: local object otherwise: non-local object (including object fields) for non-local objects: prohibit assigning non-global objects to non-local object's fields
Just add the following line before https://github.com/m-labs/artiq/blob/nac3/artiq/coredevice/core.py#L92
self.embedding_map.attributes_writeback = []