CodeQL / Analyze (actions) (push) Canceled after 0s
CodeQL / Analyze (python) (push) Canceled after 0s
pre-commit / pre-commit (push) Canceled after 0s
Multi-Arch CI / setup (push) Canceled after 0s
Publish build_manylinux_x86_64 images / publish_build_manylinux_x86_64 (push) Canceled after 0s
Setup (Multi-Arch) / setup (push) Canceled after 0s
Multi-Arch CI / Linux::${{ fromJSON(needs.setup.outputs.linux_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubi10 image / publish_no_rocm_image_ubi10 (push) Canceled after 0s
Multi-Arch CI / Windows::${{ fromJSON(needs.setup.outputs.windows_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Multi-Arch CI / Manifest Diff (push) Canceled after 0s
TheRock Manifest Diff Report / Generate Manifest Diff Report (push) Canceled after 0s
Multi-Arch CI / CI Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_ocl_rt images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_rocgdb images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Unit Tests / Unit Tests :: ubuntu-24.04 (push) Canceled after 0s
Unit Tests / Unit Tests :: windows-2022 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_media (push) Canceled after 0s
Unit Tests / Unit Tests Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_openmpi (push) Canceled after 0s
43 lines
1.8 KiB
C
43 lines
1.8 KiB
C
// RUN: %clang_cc1 -O2 -emit-obj %s -o /dev/null 2>&1 | FileCheck %s --check-prefix=DISABLED
|
|
// RUN: %clang_cc1 -O2 -emit-obj -fdiagnostics-show-inlining-chain %s -o /dev/null 2>&1 | FileCheck %s --check-prefix=ENABLED-HEURISTIC
|
|
// RUN: %clang_cc1 -O2 -emit-obj -fdiagnostics-show-inlining-chain -debug-info-kind=line-directives-only %s -o /dev/null 2>&1 | FileCheck %s --check-prefix=ENABLED-DEBUG
|
|
|
|
// Test -fdiagnostics-show-inlining-chain behavior:
|
|
// - Disabled (default): warning only, no inlining notes.
|
|
// - Enabled without debug info: heuristic fallback + suggestion note.
|
|
// - Enabled with debug info: accurate locations from DILocation.
|
|
|
|
[[gnu::warning("do not call")]]
|
|
void bad_func(void);
|
|
|
|
static inline void level1(void) {
|
|
bad_func();
|
|
}
|
|
|
|
static inline void level2(void) {
|
|
level1();
|
|
}
|
|
|
|
void entry(void) {
|
|
level2();
|
|
}
|
|
|
|
// Disabled (default): warning only, no inlining notes.
|
|
// DISABLED: warning: call to 'bad_func'
|
|
// DISABLED-NOT: note:
|
|
|
|
// Enabled without debug info: heuristic fallback.
|
|
// All notes point to original call site (:14).
|
|
// ENABLED-HEURISTIC: :14:{{.*}}: warning: call to 'bad_func'
|
|
// ENABLED-HEURISTIC: :14:{{.*}}: note: called by function 'level1'
|
|
// ENABLED-HEURISTIC: :18:{{.*}}: note: inlined by function 'level2'
|
|
// ENABLED-HEURISTIC: :22:{{.*}}: note: inlined by function 'entry'
|
|
// ENABLED-HEURISTIC: note: use '-gline-directives-only' (implied by '-g1') or higher for more accurate inlining chain locations
|
|
|
|
// Enabled with debug info: accurate locations.
|
|
// ENABLED-DEBUG: :14:{{.*}}: warning: call to 'bad_func'
|
|
// ENABLED-DEBUG: :14:{{.*}}: note: called by function 'level1'
|
|
// ENABLED-DEBUG: :18:{{.*}}: note: inlined by function 'level2'
|
|
// ENABLED-DEBUG: :22:{{.*}}: note: inlined by function 'entry'
|
|
// ENABLED-DEBUG-NOT: note: use '-gline-directives-only'
|