whitequark
e47538ca33
analyzer: explicitly delimit messages (with \x1D).
...
Fixes #461 .
2016-06-07 11:26:49 +00:00
whitequark
355af3e569
embedding: specialize inherited functions.
...
Fixes #414 .
2016-05-16 15:59:26 +00:00
whitequark
640022122b
embedding: refactor some more.
2016-05-16 14:38:09 +00:00
whitequark
d085d5a372
embedding: refactor.
2016-05-16 14:38:09 +00:00
whitequark
c94c411fd5
compiler: demangle symbols.
...
In future commits we'll add Itanium C++ ABI style mangling to ARTIQ
emitted function names.
2016-05-16 14:38:09 +00:00
whitequark
0826ceb8ba
Commit missing parts of a5bb4a24
.
2016-05-10 02:12:57 +00:00
whitequark
a5bb4a24af
compiler: support short form of raise.
...
Fixes #240 .
2016-05-10 01:41:40 +00:00
whitequark
6d29e768a5
Commit missing parts of 4e5d75295
.
2016-05-09 12:51:24 +00:00
whitequark
4e5d752951
compiler: fix quoting of methods ( fixes #423 ).
2016-05-09 12:25:57 +00:00
whitequark
f7d83e9bdf
compiler: make kernel_invariant an instance, not class, property.
...
Fixes #409 .
2016-04-29 13:06:11 +00:00
whitequark
aa0882a06f
embedding: ignore empty lines, like annotations, before kernel functions.
...
Fixes #363 .
2016-04-26 02:25:08 +00:00
whitequark
a88425b66b
compiler: allow RPCing builtin functions.
...
Fixes #366 .
2016-04-26 01:31:17 +00:00
whitequark
1464bae6b7
compiler: don't typecheck RPCs except for return type.
...
Fixes #260 .
2016-04-26 01:12:36 +00:00
whitequark
9cc9e8b276
embedding: s/kernel_constant_attributes/kernel_invariants/g
...
Requested in #359 .
2016-04-06 22:38:31 +00:00
whitequark
8b1c5e3a26
llvm_ir_generator: add fast-math flags to fcmp.
...
This is allowed in 3.8.
2016-04-05 00:48:41 +00:00
whitequark
ad83b092fa
llvm_ir_generator: change !{→unconditionally_}dereferenceable.
...
Since LLVM 3.8, !dereferenceable is weaker, so we introduce
!unconditionally_dereferenceable (http://reviews.llvm.org/D18738 )
to regain its functionality.
2016-04-05 00:48:41 +00:00
whitequark
72b952e850
llvm_ir_generator: fix DICompileUnit.language.
2016-04-05 00:48:41 +00:00
whitequark
a57aabb3ea
compiler: purge generated functions from backtraces.
2016-04-02 18:29:36 +00:00
whitequark
a1e98a4437
llvm_ir_generator: add TBAA metadata for @now.
2016-04-02 18:19:14 +00:00
whitequark
b1f371e578
llvm_ir_generator: update debug info emission for LLVM 3.8.
2016-04-02 18:05:40 +00:00
whitequark
df8018f0be
compiler: emit verbose assembly via ARTIQ_DUMP_ASM.
2016-04-01 09:34:51 +00:00
whitequark
d9dd7df3b2
compiler: add analysis passes from TargetMachine.
...
This doesn't have any effect right now, but is the right thing to do.
2016-04-01 09:34:36 +00:00
whitequark
10108e6d64
compiler: mark loaded pointers as !dereferenceable.
...
Also, lower the bound for test_pulse_rate_dds, since we generate
better code for it now.
2016-03-31 12:04:38 +00:00
whitequark
2c04979727
compiler: update for LLVM 3.7.
2016-03-31 11:23:47 +00:00
whitequark
b8bd344e54
compiler: use correct data layout.
2016-03-31 11:22:29 +00:00
whitequark
8a908a7656
llvm_ir_generator: do not use 'coldcc' calling convention.
...
First, this calling convention doesn't actually exist in OR1K
and trying to use it in Asserts build causes an UNREACHABLE.
Second, I tried to introduce it and it does not appear to produce
any measurable benefit: not only OR1K has a ton of CSRs but also
it is quite hard, if not realistically impossible, to produce
the kind of register pressure that would be relieved by sparing
a few more CSRs for our exception raising function calls, since
temporaries don't have to be preserved before a noreturn call
and spilling over ten registers across an exceptional edge
is not something that the code we care about would do.
Third, it produces measurable drawbacks: it inflates code size
of check:* functions by adding spills. Of course, this could be
alleviated by making __artiq_raise coldcc as well, but what's
the point anyway?
2016-03-29 15:19:46 +00:00
whitequark
586022023b
llvm_ir_generator: mark loads as non-null where applicable.
2016-03-29 13:34:37 +00:00
whitequark
f6b391bb4e
compiler: fix ARTIQ_DUMP_ELF.
2016-03-29 13:03:49 +00:00
whitequark
a9489246a4
llvm_ir_generator: don't mark non-constant attribute loads as invariant.
...
Oops.
2016-03-29 13:03:49 +00:00
whitequark
3ed852e077
Commit missing parts of 1d8b0d46
.
2016-03-28 21:44:31 +00:00
whitequark
1038f1321f
compiler: allow specifying per-function "fast-math" flags.
...
Fixes #351 .
2016-03-28 21:44:08 +00:00
whitequark
6f5332f892
compiler: allow flagging syscalls, providing information to optimizer.
...
This also fixes a crash in test_cache introduced in 1d8b0d46
.
2016-03-28 19:56:56 +00:00
whitequark
1d8b0d46bc
compiler: mark FFI functions as ModRef=Ref using TBAA metadata.
...
Fascinatingly, the fact that you can mark call instructions with
!tbaa metadata is completely undocumented. Regardless, it is true:
a !tbaa metadata for an "immutable" type will cause
AliasAnalysis::getModRefBehavior to return OnlyReadsMemory for that
call site.
Don't bother marking loads with TBAA yet since we already place
!load.invariant on them (which is as good as the TBAA "immutable"
flag) and after that we're limited by lack of !nonnull anyway.
Also, add TBAA analysis passes in our pipeline to actually engage it.
2016-03-28 02:52:15 +00:00
whitequark
418f0a5234
compiler: mark loads of kernel constant attributes as load invariant.
...
Also, enable LICM, since it can take advantage of this.
2016-03-28 00:44:32 +00:00
whitequark
ca7463a054
compiler: do not write back kernel constant attributes.
...
Fixes #322 .
2016-03-28 00:05:57 +00:00
whitequark
f4e6b18690
compiler: implement kernel constant attributes.
...
Part of #322 .
2016-03-27 16:10:07 +00:00
whitequark
f81930ffd6
compiler: run IPSCCP.
...
This doesn't do much, only frees some registers.
2016-03-27 02:00:05 +00:00
whitequark
7213984330
compiler: raise inliner threshold to the equivalent of -O3.
2016-03-27 01:08:13 +00:00
whitequark
e75ad3d1aa
compiler: extract runtime checks into separate cold functions.
...
This reduces register pressure as well as function size, which
favorably affects the inliner.
2016-03-27 01:02:15 +00:00
whitequark
20ad7629ac
llvm_ir_generator: generate code more amenable to LLVM's GlobalOpt.
...
This exposes almost all embedded methods to inlining, with massive
gains.
2016-03-26 21:35:48 +00:00
whitequark
186a564ba8
compiler: make quoted functions independent of outer environment.
2016-03-26 20:46:45 +00:00
whitequark
f5c720c3ee
compiler: tune the LLVM optimizer pipeline ( fixes #315 ).
2016-03-26 13:20:23 +00:00
whitequark
3ee9834197
compiler: significantly increase readability of LLVM and ARTIQ IRs.
2016-03-26 12:21:02 +00:00
whitequark
8d0566661a
compiler: quote functions directly instead of going through a local.
2016-03-25 22:35:55 +00:00
whitequark
39d23793a4
transforms.llvm_ir_generator: extract class function attributes.
...
This should give LLVM more visibility.
2016-03-25 19:01:39 +00:00
whitequark
39599d4508
compiler: get rid of the GetConstructor opcode.
2016-03-25 19:01:39 +00:00
whitequark
f4ab507ab2
Bring back target print function.
2016-03-18 04:42:06 +00:00
whitequark
ac5061c205
validators.escape: track region of arguments.
...
Fixes #232 .
2016-03-18 03:08:14 +00:00
whitequark
9492464ed9
Commit missing parts of 78fa5be
.
2016-03-18 02:15:36 +00:00
whitequark
78fa5becea
compiler: refuse to embed a function from another core device.
...
Fixes #332 .
2016-03-18 02:01:14 +00:00