COMPGROUPS.NET | Search | Post Question | Groups | Stream | About | Register

### IA64 Ruby compilation sucessful

• Email
• Follow

Thanks to Charlie Mills, who actually bothered to read the comment
in gc.c,

#if defined(__ia64__) && (!defined(__GNUC__) || __GNUC__ < 2 || defined(__OPTIMIZE__))
/* ruby crashes on IA64 if compiled with optimizer on */
/* when if STACK_LEVEL_MAX is greater than this magic number */
/* I know this is a kludge.  I suspect optimizer bug */

we got yesterday's ruby-stable-snapshot built on NASA's SGI Altix cluster,

http://www1.nasa.gov/home/hqnews/2004/jul/HQ_04243_supercomput.html

by compiling with -O0.

We briefly tried turning off the optimization only for gc.c, but
gave up quickly.

Anyway, instead of only 44 levels with the crippled stack, we
managed to get to 105k stack levels before it seg-faulted and
dumped a >2GB core(!) with our little test code,

def helloLevel level
puts "hello world! "+level.to_s
helloLevel(level+1)
end

helloLevel 0

Much rejoicing,
--
Bil from the Ruby '04 Conference


 0
Reply Bil.Kleb (900) 10/2/2004 2:32:27 PM

See related articles to this posting

Bil,

Congratulations!

Bil Kleb wrote:

> Thanks to Charlie Mills, who actually bothered to read the comment

Kudos, Charlie.

> in gc.c,

<snip>

>
Anyway, instead of only 44 levels with the crippled stack, we
> managed to get to 105k stack levels before it seg-faulted and
> dumped a >2GB core(!) with our little test code,

Just curious ... how many stack levels before it seg-faulted on the
32-bit version?

-- shanko

 0
Reply sdate (240) 10/2/2004 5:20:43 PM

Shashank Date asked:
> Bil Kleb wrote:
>>
>> Anyway, instead of only 44 levels with the crippled stack, we
>
>> managed to get to 105k stack levels before it seg-faulted and
>> dumped a >2GB core(!) with our little test code,
>
> Just curious ... how many stack levels before it seg-faulted on the
> 32-bit version?

$cat > hello.rb def helloLevel level puts "hello world! "+level.to_s helloLevel(level+1) end helloLevel 0 [Ctrl-d]$ ruby hello.rb
[..]
hello world! 4542
hello.rb:3:in helloLevel': stack level too deep (SystemStackError)
from hello.rb:3:in helloLevel'

on linux x86.  Note: it does not segfault, but raises an exception.
Adam Williams reports 1257 on OSX.3.

Regards,
--
Bil from Ruby Conf '04


 0
Reply Bil.Kleb (900) 10/2/2004 6:20:27 PM

2 Replies
44 Views

Similar Articles

12/5/2013 7:59:11 AM
[PageSpeed]

Similar Artilces:

libs compilation
We have a program, that was previous compiled by another people. We develop a library that this program loads. We have experience craches in this program. Looking at the gdb we find: #0 0xc020cc68 in kill+0x10 () from /usr/lib/libc.2 #1 0xc01a72a4 in raise+0x24 () from /usr/lib/libc.2 #2 0xc01e85f8 in abort_C+0x160 () from /usr/lib/libc.2 #3 0xc01e8654 in abort+0x1c () from /usr/lib/libc.2 #4 0xc04d3a78 in terminate+0x38 () from /usr/lib/libCsup.2 #5 0xc04cd904 in TCompTechCleanupAutomaticLocal::DestructActiveObject +0x80 () from /usr/lib/libCsup.2 #6 0xc04d131c in TExceptionActionCle

Dictionary compilation
Dear friends, I have rather moderate knowledge of FM. I use FM6. My desire is to use FM to compile a dictionary. And here come my questions: - Is it possible to arrange the records in such a way that when these records are printed out the outcome will be the familiar two-column (or more) dictionary layout? - Is it possible to export the records to a word program and then give them a dictionary layout? - Do you have any idea about previous attempts to use FM for creating dictionaries? - Is anyone kindly ready to assist me in my attempt? Thank you. Newzad Hirori In message <Jf2Fc.4070$d PARFOR Compilation Hi! ive written a code which uses par for and simplifies alot what i m doing. Im trying now to compile it and there is not much written in plain English... In the Configurations Manager i created a jobmanager (though i have no idea what that is) cause i cannot use local in compilations since its a matlab service. On top of this i slightly changed the input "pool filling" by typing defaultParallelConfig('Myconfig'); instead of the original matlabpool('open') i exported the jobmanager.mat file although inside in the Jobmanager hostname i HAD NO IDEA what to w a compilation error { Note: multi-posted to [comp.lang.c++]. -mod } Dear all, I have one line in my cpp source file. void (**fa)(char,float) = new (void [](char,float)); I tried gcc and vc express, both result in compilation error: g++ gives: error: creating array of functions vc express gives: error C2092: 'abstract declarator' array element type cannot be function Can anyone help on the error information? PS: I understand the alternative way is using 'typedef void (*FA) (char, float); new ..."; I am curious why this definition has problem. Thanks -- [ See http://www.gotw.ca/resources/clcm.htm for info about ] [ comp.lang.c++.moderated. First time posters: Do this! ] multics.cn wrote: > { Note: multi-posted to [comp.lang.c++]. -mod } > > Dear all, > I have one line in my cpp source file. > void (**fa)(char,float) = new (void [](char,float)); What is that line supposed to do? How do you propose to create an array of unspecified size? > > I tried gcc and vc express, both result in compilation error: > > g++ gives: > error: creating array of functions > vc express gives: > error C2092: 'abstract declarator' array Ruby Compilation Hi, I am compiling Ruby on IBM AIX 5.3.0.0. Version of Ruby is 1.8.6. I am compiling ruby in 32 bit mode (OBJECT_MODE=32). Commands I used are configure --with-gcc --prefix=$INSTALLPATH gmake && gmake install Configure and make are going fine. ruby -v ruby 1.8.6 (2007-03-13 patchlevel 0) [powerpc-aix5.3.0.0] But when I try to load libraries, it is throwing error ruby -d -e 'require "thread.so"' Exception `LoadError' at /disk1/home/local/RUBY//lib/ruby/1.8/powerpc-aix5.3.0.0/thread.so:0 - load failed - /d

Conditional compilation?
Is there a way to define a region of text in a .tex file that will only be included/compiled under certain conditions? What I would like here is: I have a document - say, document2.tex - containing a section of text. The text refers to another section, i.e. "...as I wrote in section~\ref{sec:othersection}". Now, document2.tex is used as \input in two different master documents - let's call them master1.tex and master2.tex. master1.tex contains \label{sec:othersection} in another \input file document1.tex, however, master2.tex does not contain document1.tex. Is there a way

Compilation puzzle
Hello everyone, I stumbled upon a java compilation puzzle that I would like to discuss with you. Let's say I have two classes Foo and Bar defined as: public class Foo { } public class Bar { public Bar(String s) {} public Bar(Foo f) {} } I can compile Foo first and then I can compile Bar with Foo in javac's classpath. So far, so good. Let's say now that I have the following Main class: public class Main { public static String main(String[] args) { for (int i = 0; i < args.length; i++) { Bar b = new Bar(args[i]); } } } That code does... not bring this issue just for argument's sake. I am in the situation where I have a jar containing Bar and Foo is in a second jar that I don't have. My code (Main) would not compile without Foo so I had to create a fake Foo class just to compile successfully. It seems kind of silly. Or did I miss something? Cheers, Thomas On Jul 1, 12:24=A0pm, Lethal Possum <lethal.pos...@gmail.com> wrote: > Hello everyone, > > I stumbled upon a java compilation puzzle that I would like to discuss > with you. > Let's say I have two classes Foo and Bar defined as: > > public

Simple compilation?
I'm trying to get a dll out of compiling the following code but I get error: "function-style initializer appears to be a function definition" Although i dont have C++ experience I thought i would get the dll without the need to understand the actual code. Any help? Thank you, Maya. #include "stdafx.h" #include <wchar.h> #include <activeds.h> #define MMC_REG_NODETYPES L"software\\microsoft\\mmc\\nodetypes" #define MMC_REG_SNAPINS L"software\\microsoft\\mmc\\snapins" // MMC Extension subkeys #define MMC_REG_EXTENSIONS L"Exten

Compilation problem
Acorn C++ 3.21. Trying to build an app that I've had no problem with before. The source file throwing up the error hasn't been modified for nearly a year and the app has been built a number of times since then. I'm getting a throwback window full of "Junk at end of # line - ignored" errors. The source file is c++.WindowManager and the start of the scrap file referred to in the throwback window is as follows: # 1 "WindowManager" /* << AT&T USL C++ Language System <3.0> 09/15/91: Acorn 0.07 (19 May 2010) >> */ /* < WindowMan

Kernel Compilation
Hi, I have working VxWorks BSP for my board. I want to build the VxWorks kernel image. What I have to do? and what are the necessary components (for minimal image), I should select? If you have any link, regarding component selection and component details, please send it to me. -Thanks K.Ananth ananthk.12@gmail.com wrote: >Hi, > I have working VxWorks BSP for my board. I want to build the >VxWorks kernel image. What I have to do? Unless you have a source license the VxWorks kernel is supplied to you only as binary libraries and you therefore do not want or need to build