Skip to content
  • erikchen's avatar
    Explicitly specify whether to emit frame pointers by default. · f7c8a0df
    erikchen authored
    All platforms now specify whether to emit frame pointers by default, rather than
    relying on default compiler options.
    
    This CL moves the logic from config("default_stack_frames") into compiler.gni.
    The former is actually the right place for the logic to live, but there exists
    code that relies on whether a frame pointer is emitted by default. Right now,
    that logic is being duplicated/guessed by the code in question. This CL at least
    unifies the logic in a single location.
    
    There current exists code that uses a preprocessor definition
    HAVE_TRACE_STACK_FRAME_POINTERS. Despite the name, the code really wants to know
    if most stacks can be unwound using stack pointers. I've renamed it to
    CAN_UNWIND_WITH_FRAME_POINTERS. Arguably, any code that uses
    CAN_UNWIND_WITH_FRAME_POINTERS is broken and should be removed, since it relies
    on the assumption that all stacks will either have or not have frame pointers,
    but that can vary TU by TU.
    
    BUG=706116, 706654
    
    Review-Url: https://codereview.chromium.org/2782063005
    Cr-Commit-Position: refs/heads/master@{#462622}
    f7c8a0df