aboutsummaryrefslogtreecommitdiff
path: root/gdb/i386-tdep.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/i386-tdep.c')
-rw-r--r--gdb/i386-tdep.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/gdb/i386-tdep.c b/gdb/i386-tdep.c
index 9b905c1..d9fa2b9 100644
--- a/gdb/i386-tdep.c
+++ b/gdb/i386-tdep.c
@@ -65,6 +65,7 @@
#include <ctype.h>
#include <algorithm>
#include <unordered_set>
+#include "producer.h"
/* Register names. */
@@ -1847,12 +1848,13 @@ i386_skip_prologue (struct gdbarch *gdbarch, CORE_ADDR start_pc)
= skip_prologue_using_sal (gdbarch, func_addr);
struct compunit_symtab *cust = find_pc_compunit_symtab (func_addr);
- /* Clang always emits a line note before the prologue and another
- one after. We trust clang to emit usable line notes. */
+ /* LLVM backend (Clang/Flang) always emits a line note before the
+ prologue and another one after. We trust clang to emit usable
+ line notes. */
if (post_prologue_pc
&& (cust != NULL
&& COMPUNIT_PRODUCER (cust) != NULL
- && startswith (COMPUNIT_PRODUCER (cust), "clang ")))
+ && producer_is_llvm (COMPUNIT_PRODUCER (cust))))
return std::max (start_pc, post_prologue_pc);
}