brintos

brintos / llvm-project-archived public Read only

0
0
Text · 3.9 KiB · e90b62d Raw
95 lines · plain
1;; This test takes a very long time2; REQUIRES: expensive_checks3 4;; This test generates 65535 relocation entries in a single section,5;; which would trigger an overflow section to be generated in 32-bit mode.6; RUN: grep -v RUN: %s | \7; RUN:   sed > %t.overflow.ll 's/SIZE/65535/;s/MACRO/#/;s/#/################/g;s/#/################/g;s/#/################/g;s/#/################/g;s/#/#_/g;s/_#_\([^#]\)/\1/;s/_/, /g;s/#/ptr @c/g;'8; RUN: llc -verify-machineinstrs -mtriple powerpc-ibm-aix-xcoff \9; RUN:     -mcpu=pwr4 -mattr=-altivec -filetype=obj -o %t.overflow.o %t.overflow.ll10; RUN: llvm-readobj --section-headers %t.overflow.o | FileCheck --check-prefix=OVERFLOW %s11 12;; This test generates 65534 relocation entries, an overflow section should13;; not be generated.14; RUN: grep -v RUN: %s | \15; RUN:   sed >%t.ll 's/SIZE/65534/;s/MACRO/#/;s/#/################/g;s/#/################/g;s/#/################/g;s/#/################/g;s/#/#_/g;s/_#_#_\([^#]\)/\1/;s/_/, /g;s/#/ptr @c/g;'16; RUN: llc -verify-machineinstrs -mtriple powerpc-ibm-aix-xcoff \17; RUN:     -mcpu=pwr4 -mattr=-altivec -filetype=obj -o %t.o %t.ll18; RUN: llvm-readobj --section-headers %t.o | FileCheck --check-prefix=XCOFF32 %s19 20;; An XCOFF64 file may not contain an overflow section header.21; RUN: llc -verify-machineinstrs -mtriple powerpc64-ibm-aix-xcoff \22; RUN:     -mcpu=pwr4 -mattr=-altivec -filetype=obj -o %t64.o %t.overflow.ll23; RUN: llvm-readobj --section-headers %t64.o | FileCheck --check-prefix=XCOFF64 %s24 25@c = external global i8, align 126@arr = global [SIZE x ptr] [MACRO], align 827 28; OVERFLOW:      Sections [29; OVERFLOW-NEXT:   Section {30; OVERFLOW-NEXT:     Index: 131; OVERFLOW-NEXT:     Name: .text32; OVERFLOW-NEXT:     PhysicalAddress: 0x033; OVERFLOW-NEXT:     VirtualAddress: 0x034; OVERFLOW-NEXT:     Size: 0x035; OVERFLOW-NEXT:     RawDataOffset: 0x8C36; OVERFLOW-NEXT:     RelocationPointer: 0x037; OVERFLOW-NEXT:     LineNumberPointer: 0x038; OVERFLOW-NEXT:     NumberOfRelocations: 039; OVERFLOW-NEXT:     NumberOfLineNumbers: 040; OVERFLOW-NEXT:     Type: STYP_TEXT (0x20)41; OVERFLOW-NEXT:   }42; OVERFLOW-NEXT:   Section {43; OVERFLOW-NEXT:     Index: 244; OVERFLOW-NEXT:     Name: .data45; OVERFLOW-NEXT:     PhysicalAddress: 0x046; OVERFLOW-NEXT:     VirtualAddress: 0x047; OVERFLOW-NEXT:     Size: 0x3FFFC48; OVERFLOW-NEXT:     RawDataOffset: 0x8C49; OVERFLOW-NEXT:     RelocationPointer: 0x4008850; OVERFLOW-NEXT:     LineNumberPointer: 0x051; OVERFLOW-NEXT:     NumberOfRelocations: 6553552; OVERFLOW-NEXT:     NumberOfLineNumbers: 6553553; OVERFLOW-NEXT:     Type: STYP_DATA (0x40)54; OVERFLOW-NEXT:   }55; OVERFLOW-NEXT:   Section {56; OVERFLOW-NEXT:     Index: 357; OVERFLOW-NEXT:     Name: .ovrflo58; OVERFLOW-NEXT:     NumberOfRelocations: 6553559; OVERFLOW-NEXT:     NumberOfLineNumbers: 060; OVERFLOW-NEXT:     Size: 0x061; OVERFLOW-NEXT:     RawDataOffset: 0x062; OVERFLOW-NEXT:     RelocationPointer: 0x4008863; OVERFLOW-NEXT:     LineNumberPointer: 0x064; OVERFLOW-NEXT:     IndexOfSectionOverflowed: 265; OVERFLOW-NEXT:     IndexOfSectionOverflowed: 266; OVERFLOW-NEXT:     Type: STYP_OVRFLO (0x8000)67; OVERFLOW-NEXT:   }68; OVERFLOW-NEXT: ]69 70; XCOFF32:       Section {71; XCOFF32:         Name: .data72; XCOFF32-NEXT:    PhysicalAddress: 0x073; XCOFF32-NEXT:    VirtualAddress: 0x074; XCOFF32-NEXT:    Size: 0x3FFF875; XCOFF32-NEXT:    RawDataOffset: 0x6476; XCOFF32-NEXT:    RelocationPointer: 0x4005C77; XCOFF32-NEXT:    LineNumberPointer: 0x078; XCOFF32-NEXT:    NumberOfRelocations: 6553479; XCOFF32-NEXT:    NumberOfLineNumbers: 080; XCOFF32-NEXT:    Type: STYP_DATA (0x40)81; XCOFF32-NEXT:  }82 83; XCOFF64:      Section {84; XCOFF64:        Name: .data85; XCOFF64-NEXT:   PhysicalAddress: 0x086; XCOFF64-NEXT:   VirtualAddress: 0x087; XCOFF64-NEXT:   Size: 0x7FFF888; XCOFF64-NEXT:   RawDataOffset: 0xA889; XCOFF64-NEXT:   RelocationPointer: 0x800A090; XCOFF64-NEXT:   LineNumberPointer: 0x091; XCOFF64-NEXT:   NumberOfRelocations: 6553592; XCOFF64-NEXT:   NumberOfLineNumbers: 093; XCOFF64-NEXT:   Type: STYP_DATA (0x40)94; XCOFF64-NEXT: }95