comphead commented on code in PR #2964:
URL: https://github.com/apache/datafusion-comet/pull/2964#discussion_r2658060782
##########
spark/src/test/scala/org/apache/spark/sql/benchmark/CometStringExpressionBenchmark.scala:
##########
@@ -81,11 +74,22 @@ object CometStringExpressionBenchmark extends
CometBenchmarkBase {
StringExprConfig("translate", "select translate(c1, '123456', 'aBcDeF')
from parquetV1Table"))
override def runCometBenchmark(mainArgs: Array[String]): Unit = {
- val values = 1024 * 1024;
+ runBenchmarkWithTable("String expressions", 1024) { v =>
+ withTempPath { dir =>
+ withTempTable("parquetV1Table") {
+ prepareTable(
+ dir,
+ spark.sql(s"SELECT REPEAT(CAST(value AS STRING), 10) AS c1 FROM
$tbl"))
Review Comment:
should we have random string lengths?
something like
```
SELECT
substring(
repeat(
value
20
),
cast(rand() * 26 as int) + 1,
cast(rand() * 20 as int) + 1
) AS random_string
FROM range(10);
```
--
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]