This is an archive of the discontinued LLVM Phabricator instance.

[Utils] Match function return type and other attributes on the definition in update_cc_test_checks
AbandonedPublic

Authored by asb on Sep 15 2022, 8:00 AM.

Details

Summary

My goal is to move over the hand-written RISC-V ABI tests to using update_cc_test_checks. A blocker on doing so is that --function-signature option doesn't generate checks of the function return type. This patch aims to rectify that. I have updated the behaviour of update_cc_test_checks whenever --function-signature is passed, but of course another option would be to add another flag so as not to perturb in-tree tests.

I've additionally found that merging of CHECK lines with identical outputs doesn't seem to work when using --filter to show only the function definition unless at least one line of the body is included (this is a separate issue, to be resolved in a separate patch). With this patch, you can do something like ./llvm/utils/update_cc_test_checks.py --function-signature --filter '^define |^entry:' --clang=build/default/bin/clang clang/test/CodeGen/RISCV/riscv-abi.cpp and it generates check lines in that file like the following (replacing manually written with auto generated lines):

-// ILP32-ILP32F-ILP32D-LABEL: define{{.*}} [2 x i32] @_Z30int32_int32_struct_inheritance14child1_int32_s([2 x i32] %a.coerce)
-// LP64-LP64F-LP64D-LABEL: define{{.*}} i64 @_Z30int32_int32_struct_inheritance14child1_int32_s(i64 %a.coerce)
+// ILP32-ILP32F-ILP32D-LABEL: define dso_local [2 x i32] @_Z30int32_int32_struct_inheritance14child1_int32_s
+// ILP32-ILP32F-ILP32D-SAME: ([2 x i32] [[A_COERCE:%.*]]) #[[ATTR0:[0-9]+]] {
+// ILP32-ILP32F-ILP32D:  entry:
+//
+// LP64-LP64F-LP64D-LABEL: define dso_local i64 @_Z30int32_int32_struct_inheritance14child1_int32_s
+// LP64-LP64F-LP64D-SAME: (i64 [[A_COERCE:%.*]]) #[[ATTR0:[0-9]+]] {
+// LP64-LP64F-LP64D:  entry:
+//

Diff Detail

Event Timeline

asb created this revision.Sep 15 2022, 8:00 AM
Herald added a project: Restricted Project. · View Herald TranscriptSep 15 2022, 8:00 AM
asb requested review of this revision.Sep 15 2022, 8:00 AM
Herald added a project: Restricted Project. · View Herald TranscriptSep 15 2022, 8:00 AM
asb edited the summary of this revision. (Show Details)Sep 15 2022, 8:00 AM
asb added a comment.Sep 29 2022, 3:46 AM

Ping - any thoughts on this?

I have also wanted this in the past, and I don't think the church should be too bad since many tests don't use this flag and if they do it will only affect a few lines without any knock on effects.

llvm/utils/UpdateTestChecks/common.py
542

How about 'funcdef'? I initially read this as being related to 'undef'.

llvm/utils/update_test_checks.py
201–202

Why is this hardcoded to false, shouldn't it match the cc test checks version and use args.function_signature?

asb updated this revision to Diff 471829.Oct 30 2022, 5:01 AM
asb retitled this revision from [Utils] [WIP/RFC] Match function return type and other attributes on the definition in update_cc_test_checks to [Utils] Match function return type and other attributes on the definition in update_cc_test_checks.
asb edited the summary of this revision. (Show Details)

Remove WIP/RFC tag, update patch based on review feedback, update tests that need changing.

Note: some in-tree update_cc_test_checks generated files will have slightly different output if re-run after this patch - unsure if I'd be best regenerating them as part of this patch, or as a follow-up?

I have also wanted this in the past, and I don't think the church should be too bad since many tests don't use this flag and if they do it will only affect a few lines without any knock on effects.

I am not 100% sure this is the case. Could we check? Grep all the tests for the flag, run the update script on them as a NFC commit after this one. Verify they all run properly and the churn is not too bad.

asb updated this revision to Diff 482709.Dec 13 2022, 9:21 PM

Rebase. Commentary on regenerating in-tree update_cc_test_checks --function-signature to follow shortly.

asb added a comment.Dec 13 2022, 9:47 PM

Submitting some comments I didn't notice were queued up.

llvm/utils/UpdateTestChecks/common.py
542

I've gone ahead and changed all 'fundef' to 'funcdef'

llvm/utils/update_test_checks.py
201–202

I think the churn converting all update_cc_test_checks files to match the function return type + attributes isn't too bad, but there are quite a lot more files that would be impacted by changing behaviour in update_test_checks.py. I'm not opposed to making that change here too, but wondered if it's worth changing behaviour for just update_cc_test_checks first?

asb added a comment.Dec 13 2022, 9:50 PM

Rebase. Commentary on regenerating in-tree update_cc_test_checks --function-signature to follow shortly.

D139994 is a patch that regenerates all --function-signature update_cc_test_checks.py tests without this patch applied. The changes after applying this patch are too large to upload to phabricator but can be seen here. The number of files touched isn't too bad, but the OpenMP tests are very large.

git grep --files-with-matches -- '--function-signature' clang/test (a slight over-estimate as not all these files are autogenerated) gives the following 238 files:

clang/test/CodeGen/2005-01-02-ConstantInits.c
clang/test/CodeGen/aarch64-neon-across.c
clang/test/CodeGen/aarch64-neon-fcvt-intrinsics.c
clang/test/CodeGen/aarch64-neon-fma.c
clang/test/CodeGen/aarch64-neon-tbl.c
clang/test/CodeGen/aarch64-poly128.c
clang/test/CodeGen/aarch64-v8.2a-neon-intrinsics.c
clang/test/CodeGen/arm-neon-fma.c
clang/test/CodeGen/arm-neon-numeric-maxmin.c
clang/test/CodeGen/arm-neon-vcvtX.c
clang/test/CodeGenCXX/pr58798.cpp
clang/test/OpenMP/align_clause_codegen.cpp
clang/test/OpenMP/amdgcn_target_global_constructor.cpp
clang/test/OpenMP/bug56913.c
clang/test/OpenMP/cancel_codegen.cpp
clang/test/OpenMP/cancellation_point_codegen.cpp
clang/test/OpenMP/debug-info-complex-byval.cpp
clang/test/OpenMP/debug-info-openmp-array.cpp
clang/test/OpenMP/declare_target_codegen_globalization.cpp
clang/test/OpenMP/declare_variant_bind_to_decl.cpp
clang/test/OpenMP/distribute_codegen.cpp
clang/test/OpenMP/distribute_firstprivate_codegen.cpp
clang/test/OpenMP/distribute_lastprivate_codegen.cpp
clang/test/OpenMP/distribute_parallel_for_codegen.cpp
clang/test/OpenMP/distribute_parallel_for_firstprivate_codegen.cpp
clang/test/OpenMP/distribute_parallel_for_if_codegen.cpp
clang/test/OpenMP/distribute_parallel_for_lastprivate_codegen.cpp
clang/test/OpenMP/distribute_parallel_for_num_threads_codegen.cpp
clang/test/OpenMP/distribute_parallel_for_private_codegen.cpp
clang/test/OpenMP/distribute_parallel_for_proc_bind_codegen.cpp
clang/test/OpenMP/distribute_parallel_for_reduction_task_codegen.cpp
clang/test/OpenMP/distribute_parallel_for_simd_codegen.cpp
clang/test/OpenMP/distribute_parallel_for_simd_firstprivate_codegen.cpp
clang/test/OpenMP/distribute_parallel_for_simd_if_codegen.cpp
clang/test/OpenMP/distribute_parallel_for_simd_lastprivate_codegen.cpp
clang/test/OpenMP/distribute_parallel_for_simd_num_threads_codegen.cpp
clang/test/OpenMP/distribute_parallel_for_simd_private_codegen.cpp
clang/test/OpenMP/distribute_parallel_for_simd_proc_bind_codegen.cpp
clang/test/OpenMP/distribute_private_codegen.cpp
clang/test/OpenMP/distribute_simd_codegen.cpp
clang/test/OpenMP/distribute_simd_firstprivate_codegen.cpp
clang/test/OpenMP/distribute_simd_lastprivate_codegen.cpp
clang/test/OpenMP/distribute_simd_private_codegen.cpp
clang/test/OpenMP/distribute_simd_reduction_codegen.cpp
clang/test/OpenMP/for_firstprivate_codegen.cpp
clang/test/OpenMP/for_lastprivate_codegen.cpp
clang/test/OpenMP/for_linear_codegen.cpp
clang/test/OpenMP/for_private_codegen.cpp
clang/test/OpenMP/for_reduction_codegen.cpp
clang/test/OpenMP/for_reduction_codegen_UDR.cpp
clang/test/OpenMP/for_reduction_task_codegen.cpp
clang/test/OpenMP/irbuilder_for_iterator.cpp
clang/test/OpenMP/irbuilder_for_rangefor.cpp
clang/test/OpenMP/irbuilder_for_unsigned.c
clang/test/OpenMP/irbuilder_for_unsigned_auto.c
clang/test/OpenMP/irbuilder_for_unsigned_down.c
clang/test/OpenMP/irbuilder_for_unsigned_dynamic.c
clang/test/OpenMP/irbuilder_for_unsigned_dynamic_chunked.c
clang/test/OpenMP/irbuilder_for_unsigned_runtime.c
clang/test/OpenMP/irbuilder_for_unsigned_static_chunked.c
clang/test/OpenMP/irbuilder_unroll_full.c
clang/test/OpenMP/irbuilder_unroll_heuristic.c
clang/test/OpenMP/irbuilder_unroll_partial_factor.c
clang/test/OpenMP/irbuilder_unroll_partial_factor_for.c
clang/test/OpenMP/irbuilder_unroll_partial_factor_for_collapse.c
clang/test/OpenMP/irbuilder_unroll_partial_heuristic.c
clang/test/OpenMP/irbuilder_unroll_partial_heuristic_constant_for.c
clang/test/OpenMP/irbuilder_unroll_partial_heuristic_for_collapse.c
clang/test/OpenMP/irbuilder_unroll_partial_heuristic_runtime_for.c
clang/test/OpenMP/irbuilder_unroll_unroll_partial_factor.c
clang/test/OpenMP/irbuilder_unroll_unroll_partial_heuristic.c
clang/test/OpenMP/master_taskloop_in_reduction_codegen.cpp
clang/test/OpenMP/master_taskloop_simd_in_reduction_codegen.cpp
clang/test/OpenMP/nvptx_allocate_codegen.cpp
clang/test/OpenMP/nvptx_data_sharing.cpp
clang/test/OpenMP/nvptx_distribute_parallel_generic_mode_codegen.cpp
clang/test/OpenMP/nvptx_lambda_capturing.cpp
clang/test/OpenMP/nvptx_multi_target_parallel_codegen.cpp
clang/test/OpenMP/nvptx_nested_parallel_codegen.cpp
clang/test/OpenMP/nvptx_parallel_codegen.cpp
clang/test/OpenMP/nvptx_parallel_for_codegen.cpp
clang/test/OpenMP/nvptx_target_codegen.cpp
clang/test/OpenMP/nvptx_target_parallel_codegen.cpp
clang/test/OpenMP/nvptx_target_parallel_num_threads_codegen.cpp
clang/test/OpenMP/nvptx_target_parallel_reduction_codegen_tbaa_PR46146.cpp
clang/test/OpenMP/nvptx_target_printf_codegen.c
clang/test/OpenMP/nvptx_target_teams_codegen.cpp
clang/test/OpenMP/nvptx_target_teams_distribute_codegen.cpp
clang/test/OpenMP/nvptx_target_teams_distribute_parallel_for_codegen.cpp
clang/test/OpenMP/nvptx_target_teams_distribute_parallel_for_generic_mode_codegen.cpp
clang/test/OpenMP/nvptx_target_teams_distribute_parallel_for_simd_codegen.cpp
clang/test/OpenMP/nvptx_teams_codegen.cpp
clang/test/OpenMP/nvptx_teams_reduction_codegen.cpp
clang/test/OpenMP/openmp_win_codegen.cpp
clang/test/OpenMP/ordered_codegen.cpp
clang/test/OpenMP/parallel_codegen.cpp
clang/test/OpenMP/parallel_copyin_codegen.cpp
clang/test/OpenMP/parallel_firstprivate_codegen.cpp
clang/test/OpenMP/parallel_for_codegen.cpp
clang/test/OpenMP/parallel_for_lastprivate_conditional.cpp
clang/test/OpenMP/parallel_for_linear_codegen.cpp
clang/test/OpenMP/parallel_for_reduction_task_codegen.cpp
clang/test/OpenMP/parallel_for_simd_aligned_codegen.cpp
clang/test/OpenMP/parallel_if_codegen.cpp
clang/test/OpenMP/parallel_if_codegen_PR51349.cpp
clang/test/OpenMP/parallel_master_codegen.cpp
clang/test/OpenMP/parallel_master_reduction_task_codegen.cpp
clang/test/OpenMP/parallel_master_taskloop_codegen.cpp
clang/test/OpenMP/parallel_master_taskloop_lastprivate_codegen.cpp
clang/test/OpenMP/parallel_master_taskloop_simd_codegen.cpp
clang/test/OpenMP/parallel_master_taskloop_simd_lastprivate_codegen.cpp
clang/test/OpenMP/parallel_private_codegen.cpp
clang/test/OpenMP/parallel_reduction_codegen.cpp
clang/test/OpenMP/parallel_reduction_task_codegen.cpp
clang/test/OpenMP/parallel_sections_codegen.cpp
clang/test/OpenMP/parallel_sections_reduction_task_codegen.cpp
clang/test/OpenMP/reduction_compound_op.cpp
clang/test/OpenMP/reduction_implicit_map.cpp
clang/test/OpenMP/sections_firstprivate_codegen.cpp
clang/test/OpenMP/sections_lastprivate_codegen.cpp
clang/test/OpenMP/sections_private_codegen.cpp
clang/test/OpenMP/sections_reduction_codegen.cpp
clang/test/OpenMP/sections_reduction_task_codegen.cpp
clang/test/OpenMP/single_codegen.cpp
clang/test/OpenMP/single_firstprivate_codegen.cpp
clang/test/OpenMP/single_private_codegen.cpp
clang/test/OpenMP/target_codegen_global_capture.cpp
clang/test/OpenMP/target_has_device_addr_codegen.cpp
clang/test/OpenMP/target_has_device_addr_codegen_01.cpp
clang/test/OpenMP/target_map_codegen_03.cpp
clang/test/OpenMP/target_offload_mandatory_codegen.cpp
clang/test/OpenMP/target_parallel_codegen.cpp
clang/test/OpenMP/target_parallel_debug_codegen.cpp
clang/test/OpenMP/target_parallel_for_codegen.cpp
clang/test/OpenMP/target_parallel_for_debug_codegen.cpp
clang/test/OpenMP/target_parallel_for_reduction_task_codegen.cpp
clang/test/OpenMP/target_parallel_for_simd_codegen.cpp
clang/test/OpenMP/target_parallel_if_codegen.cpp
clang/test/OpenMP/target_parallel_num_threads_codegen.cpp
clang/test/OpenMP/target_parallel_reduction_task_codegen.cpp
clang/test/OpenMP/target_teams_codegen.cpp
clang/test/OpenMP/target_teams_distribute_codegen.cpp
clang/test/OpenMP/target_teams_distribute_collapse_codegen.cpp
clang/test/OpenMP/target_teams_distribute_dist_schedule_codegen.cpp
clang/test/OpenMP/target_teams_distribute_firstprivate_codegen.cpp
clang/test/OpenMP/target_teams_distribute_lastprivate_codegen.cpp
clang/test/OpenMP/target_teams_distribute_parallel_for_codegen.cpp
clang/test/OpenMP/target_teams_distribute_parallel_for_collapse_codegen.cpp
clang/test/OpenMP/target_teams_distribute_parallel_for_dist_schedule_codegen.cpp
clang/test/OpenMP/target_teams_distribute_parallel_for_firstprivate_codegen.cpp
clang/test/OpenMP/target_teams_distribute_parallel_for_if_codegen.cpp
clang/test/OpenMP/target_teams_distribute_parallel_for_lastprivate_codegen.cpp
clang/test/OpenMP/target_teams_distribute_parallel_for_order_codegen.cpp
clang/test/OpenMP/target_teams_distribute_parallel_for_private_codegen.cpp
clang/test/OpenMP/target_teams_distribute_parallel_for_proc_bind_codegen.cpp
clang/test/OpenMP/target_teams_distribute_parallel_for_reduction_codegen.cpp
clang/test/OpenMP/target_teams_distribute_parallel_for_reduction_task_codegen.cpp
clang/test/OpenMP/target_teams_distribute_parallel_for_schedule_codegen.cpp
clang/test/OpenMP/target_teams_distribute_parallel_for_simd_codegen.cpp
clang/test/OpenMP/target_teams_distribute_parallel_for_simd_collapse_codegen.cpp
clang/test/OpenMP/target_teams_distribute_parallel_for_simd_dist_schedule_codegen.cpp
clang/test/OpenMP/target_teams_distribute_parallel_for_simd_firstprivate_codegen.cpp
clang/test/OpenMP/target_teams_distribute_parallel_for_simd_if_codegen.cpp
clang/test/OpenMP/target_teams_distribute_parallel_for_simd_lastprivate_codegen.cpp
clang/test/OpenMP/target_teams_distribute_parallel_for_simd_private_codegen.cpp
clang/test/OpenMP/target_teams_distribute_parallel_for_simd_proc_bind_codegen.cpp
clang/test/OpenMP/target_teams_distribute_parallel_for_simd_reduction_codegen.cpp
clang/test/OpenMP/target_teams_distribute_parallel_for_simd_schedule_codegen.cpp
clang/test/OpenMP/target_teams_distribute_private_codegen.cpp
clang/test/OpenMP/target_teams_distribute_reduction_codegen.cpp
clang/test/OpenMP/target_teams_distribute_simd_codegen.cpp
clang/test/OpenMP/target_teams_distribute_simd_collapse_codegen.cpp
clang/test/OpenMP/target_teams_distribute_simd_dist_schedule_codegen.cpp
clang/test/OpenMP/target_teams_distribute_simd_firstprivate_codegen.cpp
clang/test/OpenMP/target_teams_distribute_simd_lastprivate_codegen.cpp
clang/test/OpenMP/target_teams_distribute_simd_private_codegen.cpp
clang/test/OpenMP/target_teams_distribute_simd_reduction_codegen.cpp
clang/test/OpenMP/target_teams_map_codegen.cpp
clang/test/OpenMP/target_teams_num_teams_codegen.cpp
clang/test/OpenMP/target_teams_thread_limit_codegen.cpp
clang/test/OpenMP/task_codegen.cpp
clang/test/OpenMP/task_if_codegen.cpp
clang/test/OpenMP/task_in_reduction_codegen.cpp
clang/test/OpenMP/task_member_call_codegen.cpp
clang/test/OpenMP/task_target_device_codegen.c
clang/test/OpenMP/taskgroup_codegen.cpp
clang/test/OpenMP/taskloop_in_reduction_codegen.cpp
clang/test/OpenMP/taskloop_simd_in_reduction_codegen.cpp
clang/test/OpenMP/teams_codegen.cpp
clang/test/OpenMP/teams_distribute_codegen.cpp
clang/test/OpenMP/teams_distribute_collapse_codegen.cpp
clang/test/OpenMP/teams_distribute_dist_schedule_codegen.cpp
clang/test/OpenMP/teams_distribute_firstprivate_codegen.cpp
clang/test/OpenMP/teams_distribute_lastprivate_codegen.cpp
clang/test/OpenMP/teams_distribute_parallel_for_codegen.cpp
clang/test/OpenMP/teams_distribute_parallel_for_collapse_codegen.cpp
clang/test/OpenMP/teams_distribute_parallel_for_copyin_codegen.cpp
clang/test/OpenMP/teams_distribute_parallel_for_dist_schedule_codegen.cpp
clang/test/OpenMP/teams_distribute_parallel_for_firstprivate_codegen.cpp
clang/test/OpenMP/teams_distribute_parallel_for_if_codegen.cpp
clang/test/OpenMP/teams_distribute_parallel_for_lastprivate_codegen.cpp
clang/test/OpenMP/teams_distribute_parallel_for_num_threads_codegen.cpp
clang/test/OpenMP/teams_distribute_parallel_for_private_codegen.cpp
clang/test/OpenMP/teams_distribute_parallel_for_proc_bind_codegen.cpp
clang/test/OpenMP/teams_distribute_parallel_for_reduction_codegen.cpp
clang/test/OpenMP/teams_distribute_parallel_for_reduction_task_codegen.cpp
clang/test/OpenMP/teams_distribute_parallel_for_schedule_codegen.cpp
clang/test/OpenMP/teams_distribute_parallel_for_simd_codegen.cpp
clang/test/OpenMP/teams_distribute_parallel_for_simd_collapse_codegen.cpp
clang/test/OpenMP/teams_distribute_parallel_for_simd_dist_schedule_codegen.cpp
clang/test/OpenMP/teams_distribute_parallel_for_simd_firstprivate_codegen.cpp
clang/test/OpenMP/teams_distribute_parallel_for_simd_if_codegen.cpp
clang/test/OpenMP/teams_distribute_parallel_for_simd_lastprivate_codegen.cpp
clang/test/OpenMP/teams_distribute_parallel_for_simd_num_threads_codegen.cpp
clang/test/OpenMP/teams_distribute_parallel_for_simd_private_codegen.cpp
clang/test/OpenMP/teams_distribute_parallel_for_simd_proc_bind_codegen.cpp
clang/test/OpenMP/teams_distribute_parallel_for_simd_reduction_codegen.cpp
clang/test/OpenMP/teams_distribute_parallel_for_simd_schedule_codegen.cpp
clang/test/OpenMP/teams_distribute_private_codegen.cpp
clang/test/OpenMP/teams_distribute_reduction_codegen.cpp
clang/test/OpenMP/teams_distribute_simd_aligned_messages.cpp
clang/test/OpenMP/teams_distribute_simd_codegen.cpp
clang/test/OpenMP/teams_distribute_simd_collapse_codegen.cpp
clang/test/OpenMP/teams_distribute_simd_dist_schedule_codegen.cpp
clang/test/OpenMP/teams_distribute_simd_firstprivate_codegen.cpp
clang/test/OpenMP/teams_distribute_simd_lastprivate_codegen.cpp
clang/test/OpenMP/teams_distribute_simd_private_codegen.cpp
clang/test/OpenMP/teams_distribute_simd_private_messages.cpp
clang/test/OpenMP/teams_distribute_simd_reduction_codegen.cpp
clang/test/OpenMP/teams_firstprivate_codegen.cpp
clang/test/OpenMP/teams_private_codegen.cpp
clang/test/OpenMP/threadprivate_codegen.cpp
clang/test/OpenMP/tile_codegen.cpp
clang/test/OpenMP/vla_crash.c
clang/test/utils/update_cc_test_checks/Inputs/mangled_names.c.funcsig.expected
clang/test/utils/update_cc_test_checks/Inputs/resolve-tmp-conflict.cpp.expected
clang/test/utils/update_cc_test_checks/mangled_names.test
clang/test/utils/update_cc_test_checks/resolve-tmp-conflict.test

Seeing as there are around 300 tests inside llvm/ that use --function-signature and 200+ in clang/, maybe this needs a "only for new tests" workaround such as D140212.
The other option would be to bulk-update all affected tests once this lands, but I'm not sure how the maintainers of the affected tests feel about this.

asb added a comment.Dec 19 2022, 7:42 AM

Seeing as there are around 300 tests inside llvm/ that use --function-signature and 200+ in clang/, maybe this needs a "only for new tests" workaround such as D140212.
The other option would be to bulk-update all affected tests once this lands, but I'm not sure how the maintainers of the affected tests feel about this.

The current formulation of this patch only changes behavior for update_llc_test_checks.py to only affects the tests listed above in clang/test. I'm fairly neutral about exactly how such a change would be rolled out.

asb added a subscriber: nikic.Jan 9 2023, 6:51 AM

Happy new year everyone. As @nikic noted in D140212 it might be nice to land this before that patch (and I'm keen to move this forward as it makes a number of queued RISC-V ABI test refactorings much easier to handle). Any thoughts on how to proceed?

asb added a comment.EditedJan 20 2023, 3:37 AM

@arichardson @jdoerfert (or indeed anyone else with an interest in update_*_test_checks!): I'm really keen to move this forward in some way, as without a change along these lines landing RISC-V ABI fixes is very painful. I'm happy to do the work to get this in a form that can be landed, but it would be great to get a clear steer in one direction or another so as to not waste time.

At this point, I see a couple of options:

  • Go ahead and land this basically as written (changing the default behaviour for --function-signature in update_cc_test_checks. It doesn't touch update_llc_test_checks, as it's less clear that's useful, but I can explore if desired). Update all affected in-tree tests.
  • Change tack, and introduced a --full-function-signature argument for update_cc_test_checks that will check the return value. I can use that for the tests refactoring I want to land, and in the future --function-signature might be updated to be an alias for --full-function-signature.

What do you think of either of the above paths, or do you have other ideas in mind? Many thanks.

Abandoning for now in favour of D142373, which is hopefully easier to land due to less concern about churn for existing tests.