-
Notifications
You must be signed in to change notification settings - Fork 12.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[lldb][AIX] clang-format changes for some basic #if _AIX changes #120978
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@llvm/pr-subscribers-lldb Author: Dhruv Srivastava (DhruvSrivastavaX) ChangesThis PR is in reference to porting LLDB on AIX. Link to discussions on llvm discourse and github:
Added clang-format changes for changes related to some base #if _AIX changes Review Request: @DavidSpickett Full diff: https://github.com/llvm/llvm-project/pull/120978.diff 3 Files Affected:
diff --git a/lldb/source/Host/posix/ConnectionFileDescriptorPosix.cpp b/lldb/source/Host/posix/ConnectionFileDescriptorPosix.cpp
index 6bdc33f8923281..ab4ddbfe1fb203 100644
--- a/lldb/source/Host/posix/ConnectionFileDescriptorPosix.cpp
+++ b/lldb/source/Host/posix/ConnectionFileDescriptorPosix.cpp
@@ -119,8 +119,7 @@ bool ConnectionFileDescriptor::IsConnected() const {
ConnectionStatus ConnectionFileDescriptor::Connect(llvm::StringRef path,
Status *error_ptr) {
- return Connect(
- path, [](llvm::StringRef) {}, error_ptr);
+ return Connect(path, [](llvm::StringRef) {}, error_ptr);
}
ConnectionStatus
diff --git a/lldb/source/Host/posix/DomainSocket.cpp b/lldb/source/Host/posix/DomainSocket.cpp
index 9a0b385d998bfc..f85e1b9bbdc5c0 100644
--- a/lldb/source/Host/posix/DomainSocket.cpp
+++ b/lldb/source/Host/posix/DomainSocket.cpp
@@ -86,7 +86,8 @@ Status DomainSocket::Connect(llvm::StringRef name) {
if (error.Fail())
return error;
if (llvm::sys::RetryAfterSignal(-1, ::connect, GetNativeSocket(),
- (struct sockaddr *)&saddr_un, saddr_un_len) < 0)
+ (struct sockaddr *)&saddr_un,
+ saddr_un_len) < 0)
SetLastError(error);
return error;
diff --git a/lldb/source/Plugins/Language/ObjC/Cocoa.cpp b/lldb/source/Plugins/Language/ObjC/Cocoa.cpp
index bbe5d4c611f870..b35e27ad8123f6 100644
--- a/lldb/source/Plugins/Language/ObjC/Cocoa.cpp
+++ b/lldb/source/Plugins/Language/ObjC/Cocoa.cpp
@@ -31,7 +31,6 @@
#include "llvm/ADT/APInt.h"
#include "llvm/ADT/bit.h"
-
using namespace lldb;
using namespace lldb_private;
using namespace lldb_private::formatters;
@@ -267,21 +266,21 @@ bool lldb_private::formatters::NSIndexSetSummaryProvider(
if (class_name == "NSIndexSet" || class_name == "NSMutableIndexSet") {
// Foundation version 2000 added a bitmask if the index set fit in 64 bits
// and a Tagged Pointer version if the bitmask is small enough to fit in
- // the tagged pointer payload.
+ // the tagged pointer payload.
// It also changed the layout (but not the size) of the set descriptor.
// First check whether this is a tagged pointer. The bitmask will be in
// the payload of the tagged pointer.
uint64_t payload;
- if (runtime->GetFoundationVersion() >= 2000
- && descriptor->GetTaggedPointerInfo(nullptr, nullptr, &payload)) {
+ if (runtime->GetFoundationVersion() >= 2000 &&
+ descriptor->GetTaggedPointerInfo(nullptr, nullptr, &payload)) {
count = llvm::popcount(payload);
break;
}
// The first 32 bits describe the index set in all cases:
Status error;
uint32_t mode = process_sp->ReadUnsignedIntegerFromMemory(
- valobj_addr + ptr_size, 4, 0, error);
+ valobj_addr + ptr_size, 4, 0, error);
if (error.Fail())
return false;
// Now check if the index is held in a bitmask in the object:
@@ -292,7 +291,7 @@ bool lldb_private::formatters::NSIndexSetSummaryProvider(
if ((mode & 2) == 2) {
// The bitfield is a 64 bit uint at the beginning of the data var.
uint64_t bitfield = process_sp->ReadUnsignedIntegerFromMemory(
- valobj_addr + 2 * ptr_size, 8, 0, error);
+ valobj_addr + 2 * ptr_size, 8, 0, error);
if (error.Fail())
return false;
count = llvm::popcount(bitfield);
@@ -309,7 +308,7 @@ bool lldb_private::formatters::NSIndexSetSummaryProvider(
count = 0;
break;
}
-
+
if ((mode & 2) == 2)
mode = 1; // this means the set only has one range
else
|
labath
approved these changes
Dec 26, 2024
Request you to merge this one too. Thanks! |
DhruvSrivastavaX
added a commit
that referenced
this pull request
Jan 9, 2025
This PR is in reference to porting LLDB on AIX. Link to discussions on llvm discourse and github: 1. https://discourse.llvm.org/t/port-lldb-to-ibm-aix/80640 2. #101657 The complete changes for porting are present in this draft PR: #102601 Added some base #if _AIX changes for minimal lldb build. Added a PR for clang-format changes separately, to rebase this on later: - #120978 Review Request: @labath @DavidSpickett
github-actions bot
pushed a commit
to arm/arm-toolchain
that referenced
this pull request
Jan 10, 2025
…uild (#120979) This PR is in reference to porting LLDB on AIX. Link to discussions on llvm discourse and github: 1. https://discourse.llvm.org/t/port-lldb-to-ibm-aix/80640 2. llvm/llvm-project#101657 The complete changes for porting are present in this draft PR: llvm/llvm-project#102601 Added some base #if _AIX changes for minimal lldb build. Added a PR for clang-format changes separately, to rebase this on later: - llvm/llvm-project#120978 Review Request: @labath @DavidSpickett
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR is in reference to porting LLDB on AIX.
Link to discussions on llvm discourse and github:
The complete changes for porting are present in this draft PR:
Extending LLDB to work on AIX #102601
Added clang-format changes for changes related to some base #if _AIX changes:
Review Request: @labath @DavidSpickett