Attention is currently required from: Toon Verwaest.
1 comment:
Commit Message:
Patch Set #2, Line 7: fast-api:
nit: We usually use something like [fastcall] for related CLs.
Done
To view, visit change 2822188. To unsubscribe, or for help writing mail filters, visit settings.
Attention is currently required from: Yuki Shiino.
Patch set 3:Code-Review +1
Attention is currently required from: Yuki Shiino.
Patch set 3:Commit-Queue +2
Commit Bot submitted this change.
[fastcall] Support FastApiCallbackOptions::CreateForTesting
https://crrev.com/c/2817958 is going to support artificial
calls of NoAllocDirectCall for a testing purpose, and this
new API will be used there.
Change-Id: If47ba080eede96e91ba60b89ff502dd3d3e34b93
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2822188
Reviewed-by: Toon Verwaest <verw...@chromium.org>
Reviewed-by: Maya Lekova <msle...@chromium.org>
Commit-Queue: Yuki Shiino <yukis...@chromium.org>
Cr-Commit-Position: refs/heads/master@{#73945}
---
M include/v8-fast-api-calls.h
1 file changed, 10 insertions(+), 0 deletions(-)
diff --git a/include/v8-fast-api-calls.h b/include/v8-fast-api-calls.h
index f8b5acb..035ad38 100644
--- a/include/v8-fast-api-calls.h
+++ b/include/v8-fast-api-calls.h
@@ -194,6 +194,8 @@
namespace v8 {
+class Isolate;
+
class CTypeInfo {
public:
enum class Type : uint8_t {
@@ -322,6 +324,14 @@
*/
struct FastApiCallbackOptions {
/**
+ * Creates a new instance of FastApiCallbackOptions for testing purpose. The
+ * returned instance may be filled with mock data.
+ */
+ static FastApiCallbackOptions CreateForTesting(Isolate* isolate) {
+ return {false, {0}};
+ }
+
+ /**
* If the callback wants to signal an error condition or to perform an
* allocation, it must set options.fallback to true and do an early return
* from the fast method. Then V8 checks the value of options.fallback and if
To view, visit change 2822188. To unsubscribe, or for help writing mail filters, visit settings.