drabastomek commented on code in PR #14434:
URL: https://github.com/apache/arrow/pull/14434#discussion_r998550549


##########
cpp/src/arrow/engine/substrait/extension_set.cc:
##########
@@ -858,11 +858,27 @@ struct DefaultExtensionIdRegistry : 
ExtensionIdRegistryImpl {
 
     // -------------- Substrait -> Arrow Functions -----------------
     // Mappings with a _checked variant
-    for (const auto& function_name : {"add", "subtract", "multiply", 
"divide"}) {
+    for (const auto& function_name : {"add", "subtract", "multiply", "divide", 
"sign",
+                                      "power", "sqrt", "exp", "abs"}) {
       DCHECK_OK(
           AddSubstraitCallToArrow({kSubstraitArithmeticFunctionsUri, 
function_name},
                                   
DecodeOptionlessOverflowableArithmetic(function_name)));
     }
+
+    // Mappings for log functions
+    for (const auto& function_name : {"ln", "log10", "log2", "logb", "log1p"}) 
{
+      DCHECK_OK(
+          AddSubstraitCallToArrow({kSubstraitLogarithmicFunctionsUri, 
function_name},
+                                  
DecodeOptionlessOverflowableArithmetic(function_name)));
+    }
+
+    // Mappings for rounding functions
+    for (const auto& function_name : {"ceil", "floor"}) {
+      DCHECK_OK(
+          AddSubstraitCallToArrow({kSubstraitRoundingFunctionsUri, 
function_name},
+                                  
DecodeOptionlessOverflowableArithmetic(function_name)));

Review Comment:
   I noticed that after. Updated to `DecodeOptionlessUncheckedArithmetic`.



-- 
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: github-unsubscr...@arrow.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to