Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4338389

Linux: StackOverflowError appears during big array initialization

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Not an Issue
    • Icon: P2 P2
    • None
    • 1.3.0
    • hotspot
    • x86
    • linux



      Name: iaR10016 Date: 05/16/2000



      JDK version:
      java version "1.3.0beta"
      Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.0beta-b03)
      Java HotSpot(TM) Server VM (build 1.3.0beta-b02, mixed mode)

      OS version:
      RedHat Linux 6.1

      Unexpected StackOverflowError exception appears during big array initialization.

      JCK 1.3 Compiler test "ARR/arr020/arr02005m4" fails because of this reason.

      The array length with which initialisation fails depends on the computer's
      configaration.

      The following test example demonstrates the bug:

      ---------------------- test.java ------------------------------------------

      public class test {
        static float[] arr0 = new float[] {
        0F,1F,2F,3F,4F,5F,6F,7F,8F,9F,10F,11F,12F,13F,14F,15F,16F,17F,18F,19F,20F,21F,
        22F,23F,24F,25F,26F,27F,28F,29F,30F,31F,32F,33F,34F,35F,36F,37F,38F,39F,40F,
        41F,42F,43F,44F,45F,46F,47F,48F,49F,50F,51F,52F,53F,54F,55F,56F,57F,58F,59F,
        60F,61F,62F,63F,64F,65F,66F,67F,68F,69F,70F,71F,72F,73F,74F,75F,76F,77F,78F,
        79F,80F,81F,82F,83F,84F,85F,86F,87F,88F,89F,90F,91F,92F,93F,94F,95F,96F,97F,
        98F,99F,100F,101F,102F,103F,104F,105F,106F,107F,108F,109F,110F,111F,112F,113F,
        114F,115F,116F,117F,118F,119F,120F,121F,122F,123F,124F,125F,126F,127F,128F,
        129F,130F,131F,132F,133F,134F,135F,136F,137F,138F,139F,140F,141F,142F,143F,
        144F,145F,146F,147F,148F,149F,150F,151F,152F,153F,154F,155F,156F,157F,158F,
        159F,160F,161F,162F,163F,164F,165F,166F,167F,168F,169F,170F,171F,172F,173F,
        174F,175F,176F,177F,178F,179F,180F,181F,182F,183F,184F,185F,186F,187F,188F,
        189F,190F,191F,192F,193F,194F,195F,196F,197F,198F,199F,200F,201F,202F,203F,
        204F,205F,206F,207F,208F,209F,210F,211F,212F,213F,214F,215F,216F,217F,218F,
        219F,220F,221F,222F,223F,224F,225F,226F,227F,228F,229F,230F,231F,232F,233F,
        234F,235F,236F,237F,238F,239F,240F,241F,242F,243F,244F,245F,246F,247F,248F,
        249F,250F,251F,252F,253F,254F,255F,256F,257F,258F,259F,260F,261F,262F,263F,
        264F,265F,266F,267F,268F,269F,270F,271F,272F,273F,274F,275F,276F,277F,278F,
        279F,280F,281F,282F,283F,284F,285F,286F,287F,288F,289F,290F,291F,292F,293F,
        294F,295F,296F,297F,298F,299F,300F,301F,302F,303F,304F,305F,306F,307F,308F,
        309F,310F,311F,312F,313F,314F,315F,316F,317F,318F,319F,320F,321F,322F,323F,
        324F,325F,326F,327F,328F,329F,330F,331F,332F,333F,334F,335F,336F,337F,338F,
        339F,340F,341F,342F,343F,344F,345F,346F,347F,348F,349F,350F,351F,352F,353F,
        354F,355F,356F,357F,358F,359F,360F,361F,362F,363F,364F,365F,366F,367F,368F,
        369F,370F,371F,372F,373F,374F,375F,376F,377F,378F,379F,380F,381F,382F,383F,
        384F,385F,386F,387F,388F,389F,390F,391F,392F,393F,394F,395F,396F,397F,398F,
        399F,400F,401F,402F,403F,404F,405F,406F,407F,408F,409F,410F,411F,412F,413F,
        414F,415F,416F,417F,418F,419F,420F,421F,422F,423F,424F,425F,426F,427F,428F,
        429F,430F,431F,432F,433F,434F,435F,436F,437F,438F,439F,440F,441F,442F,443F,
        444F,445F,446F,447F,448F,449F,450F,451F,452F,453F,454F,455F,456F,457F,458F,
        459F,460F,461F,462F,463F,464F,465F,466F,467F,468F,469F,470F,471F,472F,473F,
        474F,475F,476F,477F,478F,479F,480F,481F,482F,483F,484F,485F,486F,487F,488F,
        489F,490F,491F,492F,493F,494F,495F,496F,497F,498F,499F,500F,501F,502F,503F,
        504F,505F,506F,507F,508F,509F,510F,511F,512F,513F,514F,515F,516F,517F,518F,
        519F,520F,521F,522F,523F,524F,525F,526F,527F,528F,529F,530F,531F,532F,533F,
        534F,535F,536F,537F,538F,539F,540F,541F,542F,543F,544F,545F,546F,547F,548F,
        549F,550F,551F,552F,553F,554F,555F,556F,557F,558F,559F,560F,561F,562F,563F,
        564F,565F,566F,567F,568F,569F,570F,571F,572F,573F,574F,575F,576F,577F,578F,
        579F,580F,581F,582F,583F,584F,585F,586F,587F,588F,589F,590F,591F,592F,593F,
        594F,595F,596F,597F,598F,599F,600F,601F,602F,603F,604F,605F,606F,607F,608F,
        609F,610F,611F,612F,613F,614F,615F,616F,617F,618F,619F,620F,621F,622F,623F,
        624F,625F,626F,627F,628F,629F,630F,631F,632F,633F,634F,635F,636F,637F,638F,
        639F,640F,641F,642F,643F,644F,645F,646F,647F,648F,649F,650F,651F,652F,653F,
        654F,655F,656F,657F,658F,659F,660F,661F,662F,663F,664F,665F,666F,667F,668F,
        669F,670F,671F,672F,673F,674F,675F,676F,677F,678F,679F,680F,681F,682F,683F,
        684F,685F,686F,687F,688F,689F,690F,691F,692F,693F,694F,695F,696F,697F,698F,
        699F,700F,701F,702F,703F,704F,705F,706F,707F,708F,709F,710F,711F,712F,713F,
        714F,715F,716F,717F,718F,719F,720F,721F,722F,723F,724F,725F,726F,727F,728F,
        729F,730F,731F,732F,733F,734F,735F,736F,737F,738F,739F,740F,741F,742F,743F,
        744F,745F,746F,747F,748F,749F,750F,751F,752F,753F,754F,755F,756F,757F,758F
        };
      }

      ---------------------- Output: --------------------------------------------

      $javac test.java
      An exception has occurred in the compiler (1.3.0beta). Please file a bug
      at the Java Developer Connection (http://java.sun.com/cgi-bin/bugreport.cgi).
      Include your program and the follow ing diagnostic in your report. Thank you.
      java.lang.StackOverflowError
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:63)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
      ...
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.copy(Hashtable.java:64)
              at com.sun.tools.javac.v8.util.Hashtable.dble(Hashtable.java:59)
              at com.sun.tools.javac.v8.util.Hashtable.put(Hashtable.java:91)
              at com.sun.tools.javac.v8.code.Pool.put(Pool.java:75)
              at com.sun.tools.javac.v8.code.ClassWriter.writeMethod(ClassWriter.java:505)
              at com.sun.tools.javac.v8.code.ClassWriter.writeMethods(ClassWriter.java:599)
              at com.sun.tools.javac.v8.code.ClassWriter.writeClassFile(ClassWriter.java:656)
              at com.sun.tools.javac.v8.JavaCompiler.writeClass(JavaCompiler.java:315)
              at com.sun.tools.javac.v8.JavaCompiler.genCode(JavaCompiler.java:303)
              at com.sun.tools.javac.v8.JavaCompiler.compile(JavaCompiler.java:407)
              at com.sun.tools.javac.v8.Main.compile(Main.java:247)
              at com.sun.tools.javac.Main.main(Main.java:16)
      $

      ---------------------------------------------------------------------------

      ======================================================================

            hongzh Hong Zhang
            irasunw Ira Ira (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: