Skip to content
  • rwbarton's avatar
    Test for undef bugs in the LLVM backend when validating · d50609e8
    rwbarton authored and Ben Gamari's avatar Ben Gamari committed
    In an attempt to catch bugs involving using undef values, replace
    undef literals by values likely to cause crashes or test failures.
    We do this only when validating since it is a deoptimization.
    
    This depends on D1857 to catch such bugs in the RTS (such as #11487).
    
    Test Plan:
    Did a build with
    ```
    BuildFlavour = quick-llvm
    SRC_HC_OPTS_STAGE1 = -fllvm-fill-undef-with-garbage
    ```
    The build crashed when running ghc-stage2, as expected.
    
    Reviewers: austin, bgamari
    
    Reviewed By: bgamari
    
    Subscribers: thomie
    
    Differential Revision: https://phabricator.haskell.org/D1858
    d50609e8