Chromium Code Reviews

Unified Diff: src/IceGlobalContext.h

Issue 1804133002: Subzero. Uses unique_ptrs in the emit queue. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Addresses comments. Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
« no previous file with comments | « src/IceCfg.h ('k') | src/IceGlobalContext.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/IceGlobalContext.h
diff --git a/src/IceGlobalContext.h b/src/IceGlobalContext.h
index 773faf32d7187f6f5f95f5d0e03baab7642680fa..f01ac856eecb5284f3fcff9eac5f55b0e6351e60 100644
--- a/src/IceGlobalContext.h
+++ b/src/IceGlobalContext.h
@@ -28,9 +28,11 @@
#include <array>
#include <functional>
+#include <memory>
#include <mutex>
#include <thread>
#include <type_traits>
+#include <utility>
#include <vector>
namespace Ice {
@@ -336,8 +338,8 @@ public:
void lowerJumpTables();
- void emitQueueBlockingPush(EmitterWorkItem *Item);
- EmitterWorkItem *emitQueueBlockingPop();
+ void emitQueueBlockingPush(std::unique_ptr<EmitterWorkItem> Item);
+ std::unique_ptr<EmitterWorkItem> emitQueueBlockingPop();
void emitQueueNotifyEnd() { EmitQ.notifyEnd(); }
void initParserThread() {
« no previous file with comments | « src/IceCfg.h ('k') | src/IceGlobalContext.cpp » ('j') | no next file with comments »

Powered by Google App Engine