| Commit message (Collapse) | Author | Age | Files | Lines |
|\ |
|
| |
| |
| |
| |
| |
| | |
- It is only mandatory to run it before Phi type resolver.
Change-Id: Id0eb78d58e4ac7eadb35079322e8cdf210dac79a
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
In current implementation DexFile.prepare takes a list of CstIndexMap
Those maps hold nondistinct constants, which are interned into
Sections. Because they are nondistinct, many intern attempts fail.
When compiling Music app incrementally it is 362980 failed intern
attempts vs only 142850 succesful. We can very easily save that time,
by passing to DexFile.prepare sets of distinct constants that we
compute in ConstantManager. This saves ~100ms of time.
Change-Id: Iaf8ba352f0619600642b103b3537b74608ba2f1e
|
|/
|
|
|
|
|
|
|
|
| |
When compiling Music app incrementally Jack creates 417354 instances
of DexBuffer.Section. Most of them are created internally just to
call a method on them. This patch introduces an internal section
which is reused for those internal purposes. This reduces number of
created objects by 315577, which is around 8 MB.
Change-Id: Ic28dab607095d82879461e60efff2db3dfc62f13
|
|
|
|
| |
Change-Id: I22068beaf08258e6e5c7a80e101e4aed682bd564
|
|
|
|
|
|
|
|
| |
- Try to reuse same objects (CstString, CstType and so on) each time
that it is possible.
- Replace maps by arrays when it is possible.
Change-Id: I227326bd9eb707b94a4edd8761ac06766078362f
|
|\
| |
| |
| | |
ub-jack
|
| |
| |
| |
| | |
Change-Id: Ia28ac670894233f7434053b66fb8d6664f92d2fa
|
|/
|
|
| |
Change-Id: I3cec0e9d56f55e5d784343573f99cd668b3727f2
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Profiler showed that during a Music app compilation we create
1,364,332 instances of CstStrings. They require allocation of
395MB which is 6.4% of all memory allocated. It requires 5,457,328
allocations. Most of them is done in stringToUtf8Bytes. Fortunately
only 157,495 instances actually uses the |bytes| field. This means that
if we create |bytes| lazily then we can save a lot of memory and cpu
(stringToUtf8Bytes is also a cpu hotspot).
This change makes |bytes| in CtsString lazily computed.
For Music app the memory allocation is reduced by 353MB which is 5.6% of
all memory allocated. It also saves us 3,788,436 allocations.
Change-Id: I8f2980be07da29d31fc639543dfb9b3966c8cd4e
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I profiled the incremental compilation of Music app and it showed
that we are reading and creating 1,330,524 strings from dex files
in DexBuffers. I checked and the total of strings in all dex files
represented by DexBuffers is 284979. That's around 20% of what we
were reading. The conclusion was that we read the same strings
over and over again. Then I looked at ConstantManager.addDexFile
and it striked me that we need all strings, typeIds, typeNames,
fieldIds and methodIds anyway because we iterate over them in
addDexFile. This means that we can as well read all of them
when DexBuffer is created. This way we save a lot of cpu and
memory allocations. Strings alone were taking 70MB of heap.
Now we're allocating only 20% of it.
This change speeds up incremental compilation by over 12.5%.
Change-Id: Iee18e9d17419886e552e3fd0b1143d2bb7220c9c
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Profiler showed for Music app that StringIdsSection.intern(CstString)
was called 430594 times and only 52903 times strings.get(value) in
StringIdsSection.intern(StringIdItem) returned null. This means that
377691 instances of StringIdItem were created unnecessarily.
StringIdsSection.intern(CstString) created them to be able to use
StringIdsSection.intern(StringIdItem) but inside this method CstString
is obtained from StringIdItem and StringIdItem is useless unless
strings.get(value) returns null.
Change-Id: I08978b0a28fe7bd13805e44f9d52a4bbf137fd0b
|
|
|
|
|
|
|
|
|
| |
This reverts commit 725531e58b3823e21f8350d718a2e600edd1b088
- Until 64 bit registers alignment is enabled, Jack can not generate
overlapping.
Change-Id: I3f110207a49148a019f11bf01d0c3d592e54047b
|
|
|
|
|
| |
Bug: 18198750
Change-Id: Ic091f405584cf1857eb595fdbf9a97ed9cc8113c
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| | |
- The reordering performs during instruction expansion is not correct
for all instructions, in particular for xxx/range instructions that
require sequential registers.
Change-Id: Ia06ddc74b95f656060ac6929b30eb2967ec2e48a
|
|/
|
|
|
|
|
|
|
| |
- add prepare() method that can be used when mapping
is not required during prepare stage.
(cherry picked from commit a5f57a9971c02f7d2b7de9e9cc485a516303c7ec)
Change-Id: I19113a3ed682fa104d96df5f175a936578beb6ce
|
|
|
|
|
|
| |
- Registers of LocalStart and LocalSnapshot must also be shift when it is required.
Change-Id: Ib6d605a80dea1f16f77fa188995cc9d4e6a6fa38
|
|
|
|
|
|
|
| |
- Some instructions must be skipped when shifting registers during 64-bits alignment
due to reference between instructions.
Change-Id: I168f2b30f718e48aa4cbf5833acb61374be9a18b
|
|\ |
|
| |
| |
| |
| | |
Change-Id: Ib8603253db5b1fc6c62d3a742ca718854cf8394e
|
|/
|
|
| |
Change-Id: I7d2bc7fc298c83a9869787dc1fdbaac9cffdb947
|
|
|
|
| |
Change-Id: I2de20c24cc5615adc16126a1cc485073781dda79
|
|\ |
|
| |
| |
| |
| | |
Change-Id: I8a822b7e3f0fb57ddc6259e5375a59dad64b31f5
|
|/
|
|
| |
Change-Id: I73353699430eff4d5d7a3abb42e62fe91f481a03
|
|
|
|
|
|
|
| |
- Do the sort of AnnotationDirectoryItem content earlier allows
to be deterministic with this item.
Change-Id: I43c0e957e6f44f9104dc0112414bf74ba65fcbe7
|
|
|
|
| |
Change-Id: I1c1dc471260d6c22d061151eb45c095d7b4892b8
|
|
|
|
|
|
|
| |
- Size of debug information is not longer provided but it will be
compute automatically
Change-Id: Ie46021bcc307eca0c5104f869926ee96bcf3b492
|
|
|
|
| |
Change-Id: Iee03ff5bdf7e62cd477ef471affeb6c236d3f68c
|
|
|
|
| |
Change-Id: I608305ede4cd372c49f8576d9d7741941f154d2c
|
|
|
|
| |
Change-Id: I8733b091f88ff333d7de1db9eb5485f796e6051a
|
|
|
|
| |
Change-Id: Ifebfb0cef973a6c2f8b27231afc228d95f265672
|
|
|
|
|
|
| |
This was done in accordance with master.
Change-Id: I6f3c0b67a7241d933f90fb9fcaa924ce6b028369
|
|
|
|
| |
Change-Id: I6af38cd11d7852cbb46a0a75164f1161a635a19e
|
|
|
|
| |
Change-Id: Ic4ee669aea4c361f72f991ed199fef4c6afb0df1
|
|
|
|
|
|
|
| |
- Jack generates only one move-param instruction by parameters, thus
this optimization is useless.
Change-Id: Ib2869ea9ed0a4cf99d0f2408d4962989835c2d9d
|
|\ |
|
| |
| |
| |
| |
| |
| | |
- Fix all warnings or errors related to the new config.
Change-Id: I18e70bfec36c49f02add069edbf442a70e9050cf
|
|\ \
| |/
|/| |
|
| |
| |
| |
| |
| |
| | |
Remove manifest since we only need it as a library.
Change-Id: I600eef8d93d41d87f3ec41dffbdcd48ed2ab3921
|
| |
| |
| |
| | |
Change-Id: I24df3575733efb5cc052c565e1478549d39a3b6d
|
|\ \ |
|
| |/
| |
| |
| | |
Change-Id: I85ce2bc13ffcdfc00e023bdcb0cbd1d7df5b0975
|
|\ \ |
|
| |/
| |
| |
| | |
Change-Id: I19d044336c35889b7d0b4fb6607fb2dbe49744d7
|
|/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The following alignments are done during register allocation
- Align 64-bit registers that are not parameters by modifying the method
giving the next free register to take into account alignment constraints.
- Align the first register of a range to maximize the number of 64-bit
registers that will be aligned into the range
The following alignments are done during instruction massaging
- Mov instructions inserted to transfer registers which are not compatible
with the selected instruction will use even registers for 64-bit registers
- Insert the right number of registers during instruction massaging in order
not to break alignment done by the register allocator
- Align parameters to maximize the number of 64-bit register aligned
Change-Id: Iafd85eb8455701595845803e503896247a1927bd
|
|\ |
|
| |
| |
| |
| | |
Change-Id: I22669d68720aeb5978c3c22f6b8d50cf21b8008c
|
|/
|
|
| |
Change-Id: I5f770c4a5037ef61be54bfd14815a8c31a26e2ee
|