[all-commits] [llvm/llvm-project] de3f81: [Dexter] Remove false requirement of lldb for dext...

Orlando Cazalet-Hyams via All-commits all-commits at lists.llvm.org
Wed Jan 26 03:34:13 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: de3f81557ae33a01862dd19b9db451d00737b67c
      https://github.com/llvm/llvm-project/commit/de3f81557ae33a01862dd19b9db451d00737b67c
  Author: OCHyams <orlando.hyams at sony.com>
  Date:   2022-01-26 (Wed, 26 Jan 2022)

  Changed paths:
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/penalty/missing_dex_address.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/command_line.c
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/dex_declare_address/address_after_ref.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/dex_declare_address/address_hit_count.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/dex_declare_address/expression_address.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/dex_declare_address/identical_address.cpp
    A cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/dex_declare_address/lit.local.cfg
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/dex_declare_address/multiple_address.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/dex_declare_address/offset_address.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/dex_declare_address/self_comparison.cpp
    A cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/dex_declare_file/lit.local.cfg
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/dex_declare_file/precompiled_binary_different_dir/dex_commands/source_root_dir.dex
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/dex_finish_test/default_conditional.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/dex_finish_test/default_conditional_hit_count.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/dex_finish_test/default_hit_count.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/dex_finish_test/default_simple.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/dex_finish_test/limit_steps_conditional.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/dex_finish_test/limit_steps_conditional_hit_count.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/dex_finish_test/limit_steps_hit_count.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/dex_finish_test/limit_steps_simple.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/hit_count.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_check_json_step_count.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_expect_loop.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_expect_value.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_line_mismatch.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_overlapping_ranges.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_same_line_conditional.cpp
    A cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/lit.local.cfg
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/unconditional.cpp
    R cross-project-tests/debuginfo-tests/dexter/feature_tests/commands/perfect/lit.local.cfg
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/subtools/clang-opt-bisect/clang-opt-bisect.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/subtools/test/address_printing.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/subtools/test/err_limit_steps_no_values.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/subtools/test/label_another_line.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/subtools/test/label_offset.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/subtools/test/source-root-dir.cpp
    M cross-project-tests/debuginfo-tests/dexter/feature_tests/subtools/view.cpp
    M cross-project-tests/lit.cfg.py

  Log Message:
  -----------
  [Dexter] Remove false requirement of lldb for dexter regression tests on Windows

Not quite NFC because a little work was required to configure some tests to run
on Windows at all.

Before this patch on Windows:

    $ llvm-lit cross-project-tests\debuginfo-tests\dexter\feature-tests
       Unsupported: 49
       Passed     : 23

After this patch on Windows:

    $ llvm-lit cross-project-tests\debuginfo-tests\dexter\feature-tests
       Unsupported      : 27
       Passed           : 39
       Expectedly failed:  6

There are 3 main changes here. The first is to add a few more substitutions in
cross-project-tests/lit.cfg.py so that tests need to use specific flags can
still use the dexter regression test defaults for the native platform. These
are:

     %dexter_regression_test_debugger
     %dexter_regression_test_builder
     %dexter_regression_test_cflags
     %dexter_regression_test_ldflags

Tests that now use these options and therefore can be run on Windows too
(though the second is still failing for unknown reasons):

    cross-project-tests/debuginfo-tests/dexte/feature_tests
        /subtools/clang-opt-bisect/clang-opt-bisect.cpp
        /subtools/test/source-root-dir.cpp

The second change is to remove spurious `REQUIRES: system-linux, lldb` and
`UNSUPPORTED: system-windows` directives, and make changes to lit.local.cfg
files that have the same effect. I've also added comments to the genuine
REQUIRES, UNSUPPORTED, and XFAIL directives so it's easier to understand
requirements at a glance. The most common reason for a test to not be supported
on Windows is that it uses DexLimitSteps, DexDeclareAddress, or DexCommandLine,
none of which are supported in the dbgeng driver.

There are two failures on Windows that were previously hidden, which I've
XFAILed:

    cross-project-tests/debuginfo-tests/dexter/feature_tests
        /commands/perfect/dex_finish_test/default_conditional.cpp
        /commands/perfect/dex_finish_test/default_conditional_hit_count.cpp

And two that were easy to fix:

    cross-project-tests/debuginfo-tests/dexter/feature_tests
        /commands/perfect/dex_finish_test/default_simple.cpp
        /commands/perfect/dex_finish_test/default_hit_count.cpp

Lastly, I've set three directories as unsupported.

    cross-project-tests/debuginfo-tests/dexter/feature_tests
        /commands/perfect/limit_steps
        /commands/perfect/dex_declare_address
        /commands/perfect/dex_declare_file

The first two are unsupported on Windows because they contains tests for the
DexLimitSteps and DexDeclareAddress commands which aren't supported in the
dbgeng driver. The third is unsupported on all platforms as the tests involve
invoking clang directly, which isn't currently a supported way of building
tests for dexter in lit (it can cause problems for cross compilers that can
target the host, as the tests use the default triple and linker, which may
be aligned for the default target, not host).

Tested on Windows and Linux.

Reviewed By: jmorse

Differential Revision: https://reviews.llvm.org/D118048




More information about the All-commits mailing list