Skip to content

Commit feb7036

Browse files
committed
Presubmit fix: c++ code style
1 parent 630bbdc commit feb7036

File tree

7 files changed

+17
-18
lines changed

7 files changed

+17
-18
lines changed

core/cc/interval_list.h

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -162,8 +162,8 @@ inline void CustomIntervalList<T>::replace(const T& i) {
162162
// i sits within a single interval. Split it into two.
163163
// ┏━━━━━━━━━━━━━━┓
164164
// ┗━━━━━━━━━━━━━━┛
165-
//━━━━━━━━━━━┳═─═─═─═─═─═─═─┳━━━━━━━━━━━
166-
//━━━━━━━━━━━┻─═─═─═─═─═─═─═┻━━━━━━━━━━━
165+
// ━━━━━━━━━━━┳═─═─═─═─═─═─═─┳━━━━━━━━━━━
166+
// ━━━━━━━━━━━┻─═─═─═─═─═─═─═┻━━━━━━━━━━━
167167
auto interval = mIntervals.begin() + first;
168168
mIntervals.insert(interval, *interval);
169169
last++;
@@ -172,16 +172,16 @@ inline void CustomIntervalList<T>::replace(const T& i) {
172172
// Trim end of first interval.
173173
// ┏━━━━━━━━━━━━━━━━
174174
// ┗━━━━━━━━━━━━━━━━
175-
//━━━━━━━━━━━┳═─═─╗
176-
//━━━━━━━━━━━┻─═─═┘
175+
// ━━━━━━━━━━━┳═─═─╗
176+
// ━━━━━━━━━━━┻─═─═┘
177177
auto interval = mIntervals.begin() + first;
178178
interval->adjust(interval->start(), i.start());
179179
first++; // Don't erase the first interval.
180180
}
181181
if (trimHead) {
182182
// Trim front of last interval.
183-
//━━━━━━━━━━━━━━━━┓
184-
//━━━━━━━━━━━━━━━━┛
183+
// ━━━━━━━━━━━━━━━━┓
184+
// ━━━━━━━━━━━━━━━━┛
185185
// ┌═─═─┳━━━━━━━━━━━
186186
// ╚─═─═┻━━━━━━━━━━━
187187
auto interval = mIntervals.begin() + last;

core/cc/linux/process_name.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@
1717
#include <libgen.h>
1818
#include <unistd.h>
1919

20-
#include <cstring>
2120
#include <cstdint>
21+
#include <cstring>
2222
#include <string>
2323

2424
namespace core {

core/vulkan/vk_debug_marker_layer/cc/vk_api_emitter.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ class VkApiEmitter : ThreadlocalEmitterBase {
3333

3434
void StartTracing() override;
3535
void SetupTracing(
36-
const typename perfetto::DataSourceBase::SetupArgs&) override{};
36+
const typename perfetto::DataSourceBase::SetupArgs&) override {};
3737
void StopTracing() override;
3838
void EmitDebugUtilsObjectName(uint64_t vk_device, int32_t object_type,
3939
uint64_t handle, const char* name);
@@ -50,7 +50,7 @@ class VkApiEmitter : ThreadlocalEmitterBase {
5050
: vk_device_(vk_device),
5151
object_type_(object_type),
5252
handle_(handle),
53-
name_(name){};
53+
name_(name) {};
5454

5555
uint64_t vk_device_;
5656
int32_t object_type_;

core/vulkan/vk_memory_tracker_layer/cc/memory_tracker_layer_impl.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -417,7 +417,7 @@ class HostAllocation {
417417
alignment(alignment_),
418418
scope(scope_),
419419
caller_api(caller_api_),
420-
allocator_type(allocator_type_){};
420+
allocator_type(allocator_type_) {};
421421
VulkanMemoryEventPtr GetVulkanMemoryEvent();
422422

423423
private:

gapii/cc/vulkan_extras.cpp

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1045,12 +1045,11 @@ uint32_t VulkanSpy::SpyOverride_vkAllocateMemory(
10451045
device, pAllocateInfo, pAllocator, pMemory);
10461046
auto l_physical_device =
10471047
mState.PhysicalDevices[mState.Devices[device]->mPhysicalDevice];
1048-
if (0 !=
1049-
(l_physical_device->mMemoryProperties
1050-
.mmemoryTypes[pAllocateInfo->mmemoryTypeIndex]
1051-
.mpropertyFlags &
1052-
((uint32_t)(
1053-
VkMemoryPropertyFlagBits::VK_MEMORY_PROPERTY_HOST_COHERENT_BIT)))) {
1048+
if (0 != (l_physical_device->mMemoryProperties
1049+
.mmemoryTypes[pAllocateInfo->mmemoryTypeIndex]
1050+
.mpropertyFlags &
1051+
((uint32_t)(VkMemoryPropertyFlagBits::
1052+
VK_MEMORY_PROPERTY_HOST_COHERENT_BIT)))) {
10541053
// This is host-coherent memory. Some drivers actually allocate these pages
10551054
// on-demand. This forces all of the pages to be created. This is needed as
10561055
// our coherent memory tracker relies on page-faults which interferes with

gapii/cc/vulkan_layer_extras.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ typedef struct {
115115

116116
#define VK_VERSION_MAJOR(version) ((uint32_t)(version) >> 22)
117117
#define VK_VERSION_MINOR(version) (((uint32_t)(version) >> 12) & 0x3ff)
118-
#define VK_VERSION_PATCH(version) ((uint32_t)(version)&0xfff)
118+
#define VK_VERSION_PATCH(version) ((uint32_t)(version) & 0xfff)
119119

120120
#if defined(_WIN32)
121121
#define VK_LAYER_EXPORT __declspec(dllexport)

replay2/core_utils/non_copyable.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ namespace replay2 {
2020

2121
class NonCopyable {
2222
public:
23-
NonCopyable(void){};
23+
NonCopyable(void) {};
2424
NonCopyable(const NonCopyable& rhs) = delete;
2525
NonCopyable& operator=(const NonCopyable& rhs) = delete;
2626
};

0 commit comments

Comments
 (0)