• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1// #Check that with common switch commons are added to bss or
2// #Shown as *COM* otherwise their size is discounted
3// RUN: llvm-mc %s -o %t.o -filetype=obj -triple=x86_64-pc-linux
4// RUN: llvm-size -A -common %t.o | FileCheck --check-prefix="SYSV" %s
5// RUN: llvm-size -B -common %t.o| FileCheck --check-prefix="BSD" %s
6// RUN: llvm-size -A %t.o | FileCheck --check-prefix="SYSVNOCOMM" %s
7// RUN: llvm-size -B %t.o| FileCheck --check-prefix="BSDNOCOMM" %s
8	.type	x,@object
9	.comm	x,4,4
10	.type	y,@object
11	.comm	y,4,4
12	.type	z,@object
13	.comm	z,4,4
14// SYSV:      {{[ -\(\)_A-Za-z0-9.\\/:]+}}  :
15// SYSV-NEXT: section   size   addr
16// SYSV-NEXT: .text          0      0
17// SYSV-NEXT: *COM*     12      0
18// SYSV-NEXT: Total     12
19
20// SYSVNOCOMM:      {{[ -\(\)_A-Za-z0-9.\\/:]+}}  :
21// SYSVNOCOMM-NEXT: section   size   addr
22// SYSVNOCOMM-NEXT: .text          0      0
23// SYSVNOCOMM-NEXT: Total      0
24
25// BSD:      text    data     bss     dec     hex filename
26// BSD-NEXT:    0       0      12       12       c  {{[ -\(\)_A-Za-z0-9.\\/:]+}}
27
28// BSDNOCOMM:      text    data     bss     dec     hex filename
29// BSDNOCOMM-NEXT:    0       0       0       0       0  {{[ -\(\)_A-Za-z0-9.\\/:]+}}
30