[Lldb-commits] [lldb] r340562 - Fix format string issue introduced in r340548

2019-10-04 Thread Walter Lee via lldb-commits
Author: waltl
Date: Thu Aug 23 11:26:26 2018
New Revision: 340562

URL: http://llvm.org/viewvc/llvm-project?rev=340562&view=rev
Log:
Fix format string issue introduced in r340548

Make format string portable.

Modified:
lldb/trunk/source/Plugins/Language/CPlusPlus/LibCxx.cpp

Modified: lldb/trunk/source/Plugins/Language/CPlusPlus/LibCxx.cpp
URL: 
http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/Language/CPlusPlus/LibCxx.cpp?rev=340562&r1=340561&r2=340562&view=diff
==
--- lldb/trunk/source/Plugins/Language/CPlusPlus/LibCxx.cpp (original)
+++ lldb/trunk/source/Plugins/Language/CPlusPlus/LibCxx.cpp Thu Aug 23 11:26:26 
2018
@@ -126,7 +126,7 @@ bool lldb_private::formatters::LibcxxFun
   auto default_print_on_exit = llvm::make_scope_exit(
   [&found_wrapped_function, &stream, &member__f_pointer_value]() {
 if (!found_wrapped_function)
-  stream.Printf(" __f_ = %llu", member__f_pointer_value);
+  stream.Printf(" __f_ = %" PRIu64, member__f_pointer_value);
   });
 
   lldb::addr_t address_after_vtable = member__f_pointer_value + address_size;


___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] [lldb-dap] Addressing ubsan enum usage. (PR #133542)

2025-03-28 Thread Walter Lee via lldb-commits

https://github.com/googlewalt approved this pull request.


https://github.com/llvm/llvm-project/pull/133542
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] [lldb-dap] Addressing ubsan enum usage. (PR #133542)

2025-03-28 Thread Walter Lee via lldb-commits

https://github.com/googlewalt approved this pull request.


https://github.com/llvm/llvm-project/pull/133542
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] Initialize field to appease msan (PR #141537)

2025-05-26 Thread Walter Lee via lldb-commits

https://github.com/googlewalt created 
https://github.com/llvm/llvm-project/pull/141537

Tested with lldb and lldb-dap test suites.

>From d1d4ea56e970caf92ed1e5dd5848c974e6d0b795 Mon Sep 17 00:00:00 2001
From: Walter Lee 
Date: Mon, 26 May 2025 21:15:07 -0400
Subject: [PATCH] Initialize field to appease msan

Tested with lldb and lldb-dap test suites.
---
 lldb/tools/lldb-dap/Handler/DisassembleRequestHandler.cpp | 1 +
 1 file changed, 1 insertion(+)

diff --git a/lldb/tools/lldb-dap/Handler/DisassembleRequestHandler.cpp 
b/lldb/tools/lldb-dap/Handler/DisassembleRequestHandler.cpp
index c9061ef19f17a..8825c5c6413b8 100644
--- a/lldb/tools/lldb-dap/Handler/DisassembleRequestHandler.cpp
+++ b/lldb/tools/lldb-dap/Handler/DisassembleRequestHandler.cpp
@@ -27,6 +27,7 @@ namespace lldb_dap {
 
 static protocol::DisassembledInstruction GetInvalidInstruction() {
   DisassembledInstruction invalid_inst;
+  invalid_inst.address = 0;
   invalid_inst.presentationHint =
   DisassembledInstruction::eDisassembledInstructionPresentationHintInvalid;
   return invalid_inst;

___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] Initialize field to appease msan (PR #141537)

2025-05-26 Thread Walter Lee via lldb-commits

googlewalt wrote:

I can do that.  It's probably better, though currently nothing in the struct is 
initialized.

https://github.com/llvm/llvm-project/pull/141537
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] Initialize field to appease msan (PR #141537)

2025-05-26 Thread Walter Lee via lldb-commits

googlewalt wrote:

> Do we want to do the initialization here or inside the struct definition in 
> `ProtocolTypes.h`?

Done.

https://github.com/llvm/llvm-project/pull/141537
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] Initialize field to appease msan (PR #141537)

2025-05-26 Thread Walter Lee via lldb-commits

https://github.com/googlewalt updated 
https://github.com/llvm/llvm-project/pull/141537

>From d1d4ea56e970caf92ed1e5dd5848c974e6d0b795 Mon Sep 17 00:00:00 2001
From: Walter Lee 
Date: Mon, 26 May 2025 21:15:07 -0400
Subject: [PATCH 1/2] Initialize field to appease msan

Tested with lldb and lldb-dap test suites.
---
 lldb/tools/lldb-dap/Handler/DisassembleRequestHandler.cpp | 1 +
 1 file changed, 1 insertion(+)

diff --git a/lldb/tools/lldb-dap/Handler/DisassembleRequestHandler.cpp 
b/lldb/tools/lldb-dap/Handler/DisassembleRequestHandler.cpp
index c9061ef19f17a..8825c5c6413b8 100644
--- a/lldb/tools/lldb-dap/Handler/DisassembleRequestHandler.cpp
+++ b/lldb/tools/lldb-dap/Handler/DisassembleRequestHandler.cpp
@@ -27,6 +27,7 @@ namespace lldb_dap {
 
 static protocol::DisassembledInstruction GetInvalidInstruction() {
   DisassembledInstruction invalid_inst;
+  invalid_inst.address = 0;
   invalid_inst.presentationHint =
   DisassembledInstruction::eDisassembledInstructionPresentationHintInvalid;
   return invalid_inst;

>From 2bb1851dd3d0be63461b7dc9429b568cbb8d062c Mon Sep 17 00:00:00 2001
From: Walter Lee 
Date: Mon, 26 May 2025 23:40:46 -0400
Subject: [PATCH 2/2] Move the initializion to the constructor

---
 lldb/tools/lldb-dap/Handler/DisassembleRequestHandler.cpp | 1 -
 lldb/tools/lldb-dap/Protocol/ProtocolTypes.h  | 2 ++
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/lldb/tools/lldb-dap/Handler/DisassembleRequestHandler.cpp 
b/lldb/tools/lldb-dap/Handler/DisassembleRequestHandler.cpp
index 8825c5c6413b8..c9061ef19f17a 100644
--- a/lldb/tools/lldb-dap/Handler/DisassembleRequestHandler.cpp
+++ b/lldb/tools/lldb-dap/Handler/DisassembleRequestHandler.cpp
@@ -27,7 +27,6 @@ namespace lldb_dap {
 
 static protocol::DisassembledInstruction GetInvalidInstruction() {
   DisassembledInstruction invalid_inst;
-  invalid_inst.address = 0;
   invalid_inst.presentationHint =
   DisassembledInstruction::eDisassembledInstructionPresentationHintInvalid;
   return invalid_inst;
diff --git a/lldb/tools/lldb-dap/Protocol/ProtocolTypes.h 
b/lldb/tools/lldb-dap/Protocol/ProtocolTypes.h
index 5bac62adcdd38..f5e21c96fe17f 100644
--- a/lldb/tools/lldb-dap/Protocol/ProtocolTypes.h
+++ b/lldb/tools/lldb-dap/Protocol/ProtocolTypes.h
@@ -677,6 +677,8 @@ struct DisassembledInstruction {
   /// addresses may be presented is 'invalid.'
   /// Values: 'normal', 'invalid'
   std::optional presentationHint;
+
+  DisassembledInstruction() : address(0) {}
 };
 bool fromJSON(const llvm::json::Value &,
   DisassembledInstruction::PresentationHint &, llvm::json::Path);

___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] Initialize field to appease msan (PR #141537)

2025-05-26 Thread Walter Lee via lldb-commits

https://github.com/googlewalt closed 
https://github.com/llvm/llvm-project/pull/141537
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] [lldb] Fix warnings (PR #141687)

2025-05-28 Thread Walter Lee via lldb-commits

googlewalt wrote:

I don't have any expertise in this code, but it looks like it shouldn't break 
anything and fixes a bunch of build breakages, so I'm going to check it in.

https://github.com/llvm/llvm-project/pull/141687
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] [lldb] Fix warnings (PR #141687)

2025-05-28 Thread Walter Lee via lldb-commits

https://github.com/googlewalt closed 
https://github.com/llvm/llvm-project/pull/141687
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] [lldb] Fix warnings (PR #141687)

2025-05-28 Thread Walter Lee via lldb-commits

https://github.com/googlewalt approved this pull request.


https://github.com/llvm/llvm-project/pull/141687
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits