FelixYBW commented on code in PR #5952:
URL: https://github.com/apache/incubator-gluten/pull/5952#discussion_r1694161547


##########
cpp/core/jni/JniWrapper.cc:
##########
@@ -530,16 +533,35 @@ 
Java_org_apache_gluten_vectorized_NativeColumnarToRowJniWrapper_nativeColumnarTo
     JNIEnv* env,
     jobject wrapper,
     jlong c2rHandle,
-    jlong batchHandle) {
+    jlong batchHandle,
+    jlong rowId) {
   JNI_METHOD_START
   auto columnarToRowConverter = 
ObjectStore::retrieve<ColumnarToRowConverter>(c2rHandle);
   auto cb = ObjectStore::retrieve<ColumnarBatch>(batchHandle);
-  columnarToRowConverter->convert(cb);
+  auto ctx = gluten::getRuntime(env, wrapper);
+
+  auto& conf = ctx->getConfMap();
+  int64_t column2RowMemThreshold;
+  auto it = conf.find(kColumnToRowMemoryThreshold);
+  bool confIsLegal =
+      ((it == conf.end()) ? false : std::all_of(it->second.begin(), 
it->second.end(), [](unsigned char c) {
+        return std::isdigit(c);
+      }));

Review Comment:
   The check is called every batch, it's unnecessary. Let's save the threshold



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to