Page MenuHomePhabricator

[AMDGPU] Add gfx1035 target
ClosedPublic

Authored by aakanksha555 on Jun 23 2021, 11:31 AM.

Diff Detail

Unit TestsFailed

TimeTest
1,840 msx64 debian > Clang.Driver::amdgpu-mcpu.cl
Script: -- : 'RUN: at line 7'; /var/lib/buildkite-agent/builds/llvm-project/build/bin/clang -### -target r600 -mcpu=r600 /var/lib/buildkite-agent/builds/llvm-project/clang/test/Driver/amdgpu-mcpu.cl 2>&1 | /var/lib/buildkite-agent/builds/llvm-project/build/bin/FileCheck --check-prefix=R600 /var/lib/buildkite-agent/builds/llvm-project/clang/test/Driver/amdgpu-mcpu.cl
2,790 msx64 debian > LLVM.CodeGen/AMDGPU::directive-amdgcn-target.ll
Script: -- : 'RUN: at line 1'; /var/lib/buildkite-agent/builds/llvm-project/build/bin/llc -mtriple=amdgcn-amd-amdhsa --amdhsa-code-object-version=3 -mcpu=gfx600 < /var/lib/buildkite-agent/builds/llvm-project/llvm/test/CodeGen/AMDGPU/directive-amdgcn-target.ll | /var/lib/buildkite-agent/builds/llvm-project/build/bin/FileCheck --check-prefixes=V3-GFX600 /var/lib/buildkite-agent/builds/llvm-project/llvm/test/CodeGen/AMDGPU/directive-amdgcn-target.ll
2,230 msx64 debian > LLVM.CodeGen/AMDGPU::elf-header-flags-mach.ll
Script: -- : 'RUN: at line 1'; /var/lib/buildkite-agent/builds/llvm-project/build/bin/llc -filetype=obj -march=r600 -mcpu=r600 < /var/lib/buildkite-agent/builds/llvm-project/llvm/test/CodeGen/AMDGPU/elf-header-flags-mach.ll | /var/lib/buildkite-agent/builds/llvm-project/build/bin/llvm-readobj -file-headers - | /var/lib/buildkite-agent/builds/llvm-project/build/bin/FileCheck --check-prefixes=ALL,ARCH-R600,R600 /var/lib/buildkite-agent/builds/llvm-project/llvm/test/CodeGen/AMDGPU/elf-header-flags-mach.ll
40 msx64 debian > LLVM.DebugInfo::dwarfdump-invalid.test
Script: -- : 'RUN: at line 3'; not /var/lib/buildkite-agent/builds/llvm-project/build/bin/llvm-dwarfdump /var/lib/buildkite-agent/builds/llvm-project/llvm/test/DebugInfo/Inputs/invalid.elf 2>&1 | /var/lib/buildkite-agent/builds/llvm-project/build/bin/FileCheck /var/lib/buildkite-agent/builds/llvm-project/llvm/test/DebugInfo/dwarfdump-invalid.test --check-prefix=INVALID-ELF
300 msx64 debian > LLVM.tools/llvm-objdump/ELF/AMDGPU::subtarget.ll
Script: -- : 'RUN: at line 8'; /var/lib/buildkite-agent/builds/llvm-project/build/bin/llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx1035 -filetype=obj -O0 -o /var/lib/buildkite-agent/builds/llvm-project/build/test/tools/llvm-objdump/ELF/AMDGPU/Output/subtarget.ll.tmp.o /var/lib/buildkite-agent/builds/llvm-project/llvm/test/tools/llvm-objdump/ELF/AMDGPU/subtarget.ll
View Full Test Results (11 Failed)

Event Timeline

aakanksha555 created this revision.Jun 23 2021, 11:31 AM
aakanksha555 requested review of this revision.Jun 23 2021, 11:31 AM
Herald added projects: Restricted Project, Restricted Project, Restricted Project. · View Herald TranscriptJun 23 2021, 11:31 AM
This revision is now accepted and ready to land.Jun 23 2021, 12:31 PM
foad added inline comments.Jun 24 2021, 12:16 AM
clang/test/Driver/amdgpu-mcpu.cl
138

Typo in check prefix. Why didn't this make the test fail?

llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUTargetStreamer.cpp
177

Please update this switch too.

llvm/test/CodeGen/AMDGPU/directive-amdgcn-target.ll
91

You've added a RUN line here but no checks that use the new prefix. (Doesn't that make llvm-lit complain?)

183

Add a RUN line here?

aakanksha555 marked 4 inline comments as done.

Addressed feedback; fixed typo and missing check lines.

foad added a comment.Jun 24 2021, 9:47 AM

Looks OK. Have you run check-llvm and check-clang?

Looks OK. Have you run check-llvm and check-clang?

I did, no other failing tests observed.

This revision was landed with ongoing or failed builds.Jun 24 2021, 11:34 AM
This revision was automatically updated to reflect the committed changes.
MaskRay added inline comments.Jun 24 2021, 11:39 AM
llvm/test/Object/AMDGPU/elf-header-flags-mach.yaml
189

sed can be replaced by FileCheck -D (search examples in test/tools/).

The long list becomes unwieldy now. @jhenderson Suggestions on decreasing the number of RUN lines?

jhenderson added inline comments.Jun 25 2021, 12:43 AM
llvm/test/Object/AMDGPU/elf-header-flags-mach.yaml
189

sed can be replaced by FileCheck -D (search examples in test/tools/).

Is that true in this context? The sed command is controlling input to yaml2obj, not some FileCheck stuff.

The long list becomes unwieldy now. @jhenderson Suggestions on decreasing the number of RUN lines?

I think you could use additional -D options for FileCheck. Something like the following:

# RUN: llvm-readobj ... | FileCheck --check-prefixes=ELF-ALL,ELF-AMDGCN -DNAME=EF_AMDGPU_MACH_AMDGCN_GFX1035 -DVAL=0x3D
# RUN: obj2yaml ... | FileCheck %s --check-prefixes=YAML-ALL,YAML-AMDGCN -DFLAG=EF_AMDGPU_MACH_AMDGCN_GFX1035
## Repeat for all the other values.

## NB: Some of these might be better with the -NEXT suffix.
# ELF-R600: Format: elf32-amdgpu
# ELF-R600: Arch: r600
# ELF-R600: AddressSize: 32bit

# ELF-AMDGCN: Format: elf64-amdgpu
# ELF-AMDGCN: Arch: amdgcn
# ELF-AMDGCN: AddressSize: 64bit

# ELF-ALL:      Flags [
# ELF-ALL-NEXT:   [[NAME]] ([[VAL]])
# ELF-ALL-NEXT: ]

# YAML-R600:   Class: ELFCLASS32
# YAML-AMDGCN: Class: ELFCLASS64
# YAML-ALL:    Flags: [ [[FLAG]] ]