Convert byte code - optimized dex. Error - Need Help Pls :(

Joel Fonseca

Member
Licensed User
Hello,

My application was going OK, then I had more Modules, more Layouts, when I finished adding what I wanted, I tried to compile and this error starts to appear and I can't compile this any more, anyone can help me out pls ?, thanks in advance.

B4X:
Compiling code.                         3.84
Generating R file.                      0.00
Compiling generated Java code.          26.37
Convert byte code - optimized dex.      Error
UNEXPECTED TOP-LEVEL ERROR:
java.lang.OutOfMemoryError: Java heap space
   at com.android.dx.util.Bits.makeBitSet(Bits.java:38)
   at com.android.dx.util.BitIntSet.<init>(BitIntSet.java:35)
   at com.android.dx.ssa.SetFactory.makeDomFrontSet(SetFactory.java:66)
   at com.android.dx.ssa.DomFront.run(DomFront.java:107)
   at com.android.dx.ssa.SsaConverter.placePhiFunctions(SsaConverter.java:298)
   at com.android.dx.ssa.SsaConverter.convertToSsaMethod(SsaConverter.java:52)
   at com.android.dx.ssa.Optimizer.optimize(Optimizer.java:99)
   at com.android.dx.ssa.Optimizer.optimize(Optimizer.java:73)
   at com.android.dx.dex.cf.CfTranslator.processMethods(CfTranslator.java:269)
   at com.android.dx.dex.cf.CfTranslator.translate0(CfTranslator.java:131)
   at com.android.dx.dex.cf.CfTranslator.translate(CfTranslator.java:85)
   at com.android.dx.command.dexer.Main.processClass(Main.java:369)
   at com.android.dx.command.dexer.Main.processFileBytes(Main.java:346)
   at com.android.dx.command.dexer.Main.access$400(Main.java:59)
   at com.android.dx.command.dexer.Main$1.processFileBytes(Main.java:294)
   at com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:134)
   at com.android.dx.cf.direct.ClassPathOpener.processDirectory(ClassPathOpener.java:190)
   at com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:122)
   at com.android.dx.cf.direct.ClassPathOpener.processDirectory(ClassPathOpener.java:190)
   at com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:122)
   at com.android.dx.cf.direct.ClassPathOpener.processDirectory(ClassPathOpener.java:190)
   at com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:122)
   at com.android.dx.cf.direct.ClassPathOpener.processDirectory(ClassPathOpener.java:190)
   at com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:122)
   at com.android.dx.cf.direct.ClassPathOpener.processDirectory(ClassPathOpener.java:190)
   at com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:122)
   at com.android.dx.cf.direct.ClassPathOpener.process(ClassPathOpener.java:108)
   at com.android.dx.command.dexer.Main.processOne(Main.java:313)
   at com.android.dx.command.dexer.Main.processAllFiles(Main.java:233)
   at com.android.dx.command.dexer.Main.run(Main.java:185)
   at com.android.dx.command.dexer.Main.main(Main.java:166)
   at com.android.dx.command.Main.main(Main.java:90)
   Standard dexer.

My appz has:

- 272 Module Files
- 1.021 items including pictures + layout files on the "Files" directory
- The entire project folder has 57 MB of files

Is there any limitation in the project structure before starting to give this error?

I have 4GB of ram, available now it's: 1819MB

Help needed to keep me on this project pls.

Thanks in advance,

Joel
 

cocale2001

Member
Licensed User
i have only this path :
C:\Users\b.paolo\Application Data\
in this path there is only microsoft subdir.
 

Attachments

  • a.png
    a.png
    87.5 KB · Views: 194
  • b.png
    b.png
    52.2 KB · Views: 209
Upvote 0

Davin

Member
Licensed User
btw.. some stupid thing.. previously i try have some problem with my project and try this solution. but for some reason i dont have rapid debugging menu.. anyone know how to enable it back ?
 
Upvote 0

Peekay

Active Member
Licensed User
I have this error appearing all of a sudden:
Convert byte code - optimized dex. Error
It is a very small app with about 7 views and one page. It happened when I all of sudden was told that I do not have the core-3.2.1.jar library, which I then loaded and then this friend started to bug me.
 
Upvote 0

Peekay

Active Member
Licensed User
I have this error appearing all of a sudden:
Convert byte code - optimized dex. Error
It is a very small app with about 7 views and one page. It happened when I all of sudden was told that I do not have the core-3.2.1.jar library, which I then loaded and then this friend started to bug me.
I think it has to do with the barcode scanner.
 
Upvote 0

billyn_hk

Member
Licensed User
Hi Erel,

I would like to put an update on this regarding not enough space

My PC is win 7 with 4G Ram, it runs b4x from 3.x~ 5.x well
but when upgraded to 6.x, it always prompt Not enough space reserved for VM even after pure reboot.

the PC system is capable of open so many tasks and even photoshop CS and Dreamweave developers.

I though it is the memory arrangement upon compiling in B4X which had lead to this symptom.

We cannot update to 64Bit, cos some legacy system still need support via 32Bit win7.

I believe there are still tons of ppl on 32bit. and these are mostly developer for hardware system whom need to support factory type models.
and it is these ppl whom are on IT fields responsible for developing, you cannot neglect this market.

I hope you could make a work around for this.

I try to decrease from 1024 to 512, and it seems works temporary, but I though it might lead to some problem soon.

thanks
billy
 
Upvote 0
Top