Hi, the 4GB memory limit still applies (there's no way around it, you simply can't address more with 32 bit pointers!).
Cheers, Guido -- GUIDO TACK Senior Lecturer Information Technology Monash University Level 6, Room 6.40, Building H, Caulfield Campus 900 Dandenong Road Caulfield East VIC 3145 Australia T: +61 3 9903 1214 E: guido.t...@monash.edu <mailto:guido.t...@monash.edu> http://www.csse.monash.edu/~guidot/ <http://www.csse.monash.edu/~guidot/> > On 22 Nov. 2016, at 8:35 am, Alexander Schuppisser <a.schuppis...@optor.ch> > wrote: > > Hi Christian, > > thank you and sorry for being off-topic. That helped! I could compile for > 32bit under Ubuntu 14.04 64 bit with gcc like that: > --snip-- > sudo apt-get install gcc-multilib g++-multilib > cd gecode-5.0.0 > ./configure CC="gcc -m32" CXX="g++ -m32" ... > --snap-- > For others: I had to start with a vanilla gecode-source-tree, after compiling > for 64bit and "make clean" it would not work compiling for 32bit. I got this > error: "./gecode/flatzinc/parser.hh:68:41: fatal error: > gecode/flatzinc/parser.tab.hh" in the part. deleting the sources and > starting directly with 32 bit worked. > > Now I have a working 32bit gecode. Sadly, my fzn-Files doesn't work, I get > the foloowing error in 32bit (64bit working): > --snip-- > terminate called after throwing an instance of 'Gecode::MemoryExhausted' > what(): Memory: Heap memory exhausted > --snap-- > It seems to happen around 4 GB Memory being allocated. Now I wonder: I > thought the 4 GB Memory-size limit under 32bit has been circumvented under > Linux? > Do I have do set something before compiling or do I have to do some trick > before the run like calling ulimit or alike? Or is it just a limit I have to > accept? > > Thank you > Alexander > > > Am 20.11.2016 um 14:33 schrieb Christian Schulte: >> Hi, >> >> Even though this is not really a Gecode-related question, the catch is that >> you need to pick up the right compiler, either 64 or 32 bit. You have to >> figure this out for your platform. >> >> Let's assume the C++ compiler for 32 bit is called g++-32 (that's most >> likely wrong) and the C compiler is called gcc-32 (again, made up) then you >> can set the environment variable CXX and CC before you run configure to >> point to the right C++ and C compilers (one can also pass that to make by >> make CXX=g++-32 CC=gcc-32). >> >> Hope that helps >> Christian >> >> -- >> Christian Schulte, www.gecode.org/~schulte <http://www.gecode.org/%7Eschulte> >> Professor of Computer Science, KTH, cschu...@kth.se <mailto:cschu...@kth.se> >> Expert Researcher, SICS, cschu...@sics.se <mailto:cschu...@sics.se> >> -----Original Message----- >> From: users-boun...@gecode.org <mailto:users-boun...@gecode.org> >> [mailto:users-boun...@gecode.org <mailto:users-boun...@gecode.org>] On Behalf >> Of Alexander Schuppisser >> Sent: Saturday, November 19, 2016 23:37 >> To: users@gecode.org <mailto:users@gecode.org> >> Subject: [gecode-users] Compile gecode for 32-bit under Linux >> >> Hi, >> >> I'd like to compare the performance of a 64-bit version of fzn-gecode to a >> 32-bit-version unter Linux (Ubuntu 16.04 or 14.04) for a certain problem. >> But I could not crosscompile it. >> >> I know that it's possible, because in the Minizinc IDE is a fzn-gecode for >> 32 bit. But this version has dependencies to Qt (which I don't have running >> it on a server). That's how I compile what I need on 64 bit: >> >> static: >> >> export PREFIX="/home/nath/apps/gecode-5.0.0" >> ./configure \ >> --prefix="$PREFIX" --enable-float-vars=no --enable-examples=no >> --enable-qt=no --enable-gist=no --enable-doc-dot=no \ >> --enable-doc-tagfile=no --enable-driver=no --enable-examples=no >> --enable-scheduling=no --enable-graph=no --enable-minimodel=no \ >> --enable-static --disable-shared >> >> shared: >> >> export PREFIX="/home/nath/apps/gecode-5.0.0" >> CFLAGS="-Wl,-rpath,$PREFIX/lib" CXXFLAGS="-Wl,-rpath,$PREFIX/lib" \ >> ./configure \ >> --prefix="$PREFIX" --enable-float-vars=no --enable-examples=no >> --enable-qt=no --enable-gist=no --enable-doc-dot=no \ >> --enable-doc-tagfile=no --enable-driver=no --enable-examples=no >> --enable-scheduling=no --enable-graph=no --enable-minimodel=no >> >> Now what to cange / add to get a 32-bit binary in the end? >> >> I tried a lot of things with Flags and setting env-Variables before >> compiling found as general tips for cross compiling, but nothing worked for >> fzn-gecode. What do I need to do? >> >> Thank you >> >> Alexander >> > > _______________________________________________ > Gecode users mailing list > users@gecode.org > https://www.gecode.org/mailman/listinfo/gecode-users
_______________________________________________ Gecode users mailing list users@gecode.org https://www.gecode.org/mailman/listinfo/gecode-users