Commit Graph

153 Commits

Author SHA1 Message Date
Nicholas Nethercote
97e38dea03 Bug 518242 - NJ: Remove insSkip and supporting machinery. r=graydon.
--HG--
extra : convert_revision : d0134ea858d0e34c389868a59aac7085451865b4
2009-11-13 16:18:40 +11:00
Nicholas Nethercote
ce6dd615de Bug 513865 - nanojit: make LirReader::read() clearer and faster. r=gal.
--HG--
extra : convert_revision : d78bd673c8652d17489559744f4a221c78811286
2009-11-13 09:26:26 +11:00
Edwin Smith
d7a89e77b5 Add LIR_jtbl instruction, and patch up lirasm to remove LIR_ji (bug 465582 r=nnethercote+, rreitmai+)
new opcode: LIR_jtbl.  jtbl takes a uint32_t index and a table of label
references (LIns**), representing a jump to one of the labels.

the index must be in range (range checking is not included in the opcode).

the table is allocated in memory at least as long lived as the LIR; this is
accomplished by doing the allocation from the same Allocator used by LirBuffer.

In the x86 backend, this is implemented with a simple jmp [R*4+ADDR] where ADDR
is the address of the table.  I added a new dataAllocator (Allocator&)
parameter to Assembler, which is used for allocating data along with code (data
& code have same lifetime).  The x86 backend allocates the final table of
addresses from this allocator and embeds the pointer to the table in code.

In other backends more than one instruction must be used due to limited range
of the constant part of the addressing mode (ppc, arm), or non-support for
full-range pc-relative indexing (x64, ppc64).

Anyone generating LIR code for use with LIR_jtbl must also generate a
LIR_regfence instruction after each label reachable by a forwards edge
from LIR_jtbl.  This is to workaround the register allocator's inability
to merge register states between 2 or more pre-existing targets.  LIR_regfence
is not required for backwards edges.

--HG--
extra : convert_revision : ee709eaaa30f720f77ab863ba4c9e6d10d69982b
2009-11-11 14:38:12 -05:00
Graydon Hoare
53519f8859 Bug 527178 - Improve valid-displacement checks, r=edwsmith, r=dvander.
--HG--
extra : rebase_source : b95743173b293bd4a2a54b37124d4e85cb16d425
extra : convert_revision : eadf0b1a3fd0bd28303b12b905eb94a09a2ade1b
2009-11-10 14:55:35 -08:00
Nicholas Nethercote
8b9cbc6e8b Bug 525437 - clean up LIR_call. r=edwsmith.
--HG--
extra : convert_revision : 2f6b3b6eedb27044cc7699c923d4220dd169b823
2009-11-10 14:12:18 +11:00
Nicholas Nethercote
dd4a2ec015 Bug 512634 - nanojit: identify RegAlloc invariants. r=edwsmith.
--HG--
extra : convert_revision : 2d5d94694fceca54934270a518a5b341ce13b2d0
2009-11-05 11:56:48 +11:00
Nicholas Nethercote
13dad87c06 Bug 502778 - nanojit: speed up CseFilter. r=edwsmith.
--HG--
extra : convert_revision : 98b64e95f3f98c85e4dfab9e66d16543cb27a8b6
2009-11-05 09:40:33 +11:00
Graydon Hoare
108c884253 Bug 522591 - move reader pipeline from assemble() to compile(), r=gal. 2009-10-23 14:58:10 -07:00
Graydon Hoare
426e720124 Bug 522413 - remove uses of static avmcore::config, r=gal. 2009-10-15 16:02:59 -07:00
Graydon Hoare
bb3cb0015c Bug 522363 - remove debug-break, unused parameters on displacement check, r=dvander.
--HG--
extra : rebase_source : 13ef7b6d16e5b66bb70816cfdd417ab4f9bcd758
2009-10-14 15:30:00 -07:00
Andreas Gal
caf1760bb4 ARM backend does not support displacements > 12bits (519805, r=graydon). 2009-10-02 18:25:36 -07:00
Graydon Hoare
59db3f60b0 Bug 519575 - NJ merge: more LIR.h drift, r=gal. 2009-09-29 16:36:37 -07:00
Brendan Eich
4bf4354638 High-level CSE for shape guards (518448, r=jorendorff). 2009-09-29 19:05:19 -07:00
Robert Sayre
6b74778c56 Merge backout. 2009-09-26 18:58:56 -07:00
Robert Sayre
7e3d716d38 Backed out changeset f5ea964eb493sdf 2009-09-26 18:55:25 -07:00
Brendan Eich
69fd06459c High-level CSE for shape guards (518448, r=jorendorff). 2009-09-25 14:07:08 -07:00
Nicholas Nethercote
9598899fc8 Bug 518477 - NJ merge: LIR.{cpp,h} changes from TR. r=graydon. 2009-09-24 10:42:25 +10:00
Graydon Hoare
a18f57ecfd Bug 495734 - NJ: don't store non-LIR data in LIR buffers, r=gal.
--HG--
extra : rebase_source : 4a73fd251f3077fe3623ef1341a8aa3729a4e8bf
2009-09-22 16:06:52 -07:00
Nicholas Nethercote
401cfd7471 Bug 518061 - NJ merge: add ExprFilter::insLoad(). r=graydon. 2009-09-22 17:21:59 +10:00
Graydon Hoare
e102fc5e1c Bug 517299 - Allocator mismatch (calloc+delete) for class TraceRecorder and LirWriter, r=gal. 2009-09-21 14:06:42 -07:00
Graydon Hoare
c421bb6e66 Bug 517530 - NJ merge: whitespace, equivalent code, PPC churn, r=dvander. 2009-09-18 13:31:09 -07:00
Graydon Hoare
963fd74e53 Bug 516620 - Kill off residue of MMgc, r=gal.
--HG--
extra : rebase_source : 1bd814f499014507fb60ad554687b12b9fe09a3e
2009-09-10 16:29:36 -07:00
Graydon Hoare
2521578c2d Backed out changeset 35777195800a, perf regression. 2009-09-14 21:07:57 -07:00
Graydon Hoare
5d33edd2e9 Bug 516620 - Kill off residue of MMgc, r=gal. 2009-09-10 16:29:36 -07:00
Graydon Hoare
ee59e42dc3 Bug 518730 - TM: change the allocators to calloc, r=gal. 2009-09-25 15:16:10 -07:00
Nicholas Nethercote
a5ab37ac5f Fix bustage caused by the patch for 514066. 2009-09-10 14:24:57 +10:00
Nicholas Nethercote
b29cd64403 Bug 514066 - TM: Make short functions in LIR.cpp inline. r=gal. 2009-09-10 14:02:59 +10:00
Nicholas Nethercote
f110b091bc Bug 514349 - nanojit: start to kill Reservations. r=edwsmith,rreitmai. 2009-09-10 11:00:18 +10:00
David Anderson
22a1120a3e Added LIR helpers for x64 code generation (bug 514532, r=edwsmith). 2009-09-09 11:15:48 -07:00
Nicholas Nethercote
21dbf49f8b Bug 515138 - TM/nanojit: merge the two StackFilter passes. r=gal. 2009-09-09 11:48:30 +10:00
Nicholas Nethercote
6ee8551d7d Bug 512824 - TM: gcc complains about invalid aliasing in LIR.h. r=gal. 2009-09-09 09:18:41 +10:00
David Anderson
0650a2788b LIR sanity checker from tamarin-redux (bug 514503, r=gal,edwsmith). 2009-09-04 17:56:22 -07:00
Nicholas Nethercote
ea4545c24a Follow-up to bug 513843. r=gal (via IRC). 2009-09-04 11:07:36 +10:00
Andreas Gal
6771d193dd Introduce a register fence instruction to force all registers to be spilled (514374, r=edwsmith,rreitmai). 2009-09-03 14:43:30 -07:00
Nicholas Nethercote
5adc17c6a5 Bug 514110 - nanojit: avoid getresv() because it has a redundant test. r=gal. 2009-09-03 09:36:51 +10:00
Nicholas Nethercote
320a2cfb64 Backed out changeset 48928150aa27 due to Tinderbox breakage. 2009-09-02 12:14:09 +10:00
Nicholas Nethercote
85c5abe0a7 Bug 513865 - nanojit: make LirReader::read() clearer and faster. r=gal. 2009-09-02 10:20:28 +10:00
David Anderson
21466cd521 Added LIR_float to distinguish NULL from 0.0 on x64 (bug 513838, r=gal,rreitmai). 2009-09-01 14:26:24 -07:00
Andreas Gal
64b13a5ec6 Remove useless FASTCALL declarations and make hashcode and equals less branchy (513539, r=dvander). 2009-08-30 00:11:12 -07:00
Andreas Gal
317b5f2e3a Remove explicitSavedRegs and loop hacks from nanojit (513139, r=dvander). 2009-08-27 18:46:45 -07:00
Graydon Hoare
5b06cc0665 Bug 510602 - Massage LIR opcodes to merge state, r=dvander. 2009-08-27 17:52:46 -07:00
David Anderson
83d28f8a00 Merged LIR_alloc changes from tamarin-redux (bug 513069, r=gal). 2009-08-27 13:22:30 -07:00
David Anderson
32cdaad163 Merged 64-bit arithmetic ops from tamarin-redux (bug 512836, r=gal). 2009-08-26 17:14:18 -07:00
David Anderson
83fc2d7e10 Merge 64-bit comparison opcodes from tamarin-redux (bug 512826, r=gal). 2009-08-26 16:30:23 -07:00
Graydon Hoare
503c025d90 Bug 511309 - Delete class Fragmento and all uses of it, r=dvander.
--HG--
extra : rebase_source : 47047589288ac0758e0068307b5a8f393db97606
2009-08-20 17:22:47 -07:00
Edwin Smith
87b101337d Bug 510545 - Convert LInsHashSet to use Allocator instead of GC, r=gal.
--HG--
extra : rebase_source : 233cf623b49f030ca083ba250294e00b61afdac5
2009-08-06 09:41:07 -04:00
Edwin Smith
fa572124fd Bug 510116 - Remove dead code paths and arguments in nanojit::compile, r=gal. 2009-08-05 15:06:00 -04:00
Edwin Smith
83930e09a2 Bug 510095 - allocate LirBuffer with Allocator instead of GC, don't extend GCFinalizedObject, r=gal.
--HG--
extra : rebase_source : 42aa431e0d795351860f0794ea0392e1f663132b
2009-08-04 15:03:34 -04:00
Edwin Smith
ad06720f03 Bug 510078 - Convert LirNameMap to HashMap<> and Allocator, r=gal.
* * *
Don't allocate CodeAlloc with GC and dont extend GCFinalizedObject (bug 506390 r=tharwood+)

* Change PageMgr::CodeAlloc from pointer to embedded instance.
* Assembler takes CodeAlloc& now, like it already does for Allocator&
* PoolObject.cpp|h now use VMCFG_NANOJIT instead of (deprecated) FEATURE_NANOJIT
  (both #defines are equivalent)

--HG--
extra : rebase_source : 90847a654d7f669a4c2ac364dd9aae7be38cae77
2009-08-04 14:18:38 -04:00
Edwin Smith
3967b233d5 Bug 510036 - Convert LabelMap to HashMap<> and Allocator, r=gal.
--HG--
extra : rebase_source : 4f1385922085fe086084c418aa22dcc4cc4c1961
2009-08-04 13:56:48 -04:00