提交 0159c106 编写于 作者: Z zhaoyanggh

win compile

上级 aafd7e1d
...@@ -87,8 +87,8 @@ void *specifiedTableQuery(void *sarg) { ...@@ -87,8 +87,8 @@ void *specifiedTableQuery(void *sarg) {
while (queryTimes--) { while (queryTimes--) {
if (g_queryInfo.specifiedQueryInfo.queryInterval && if (g_queryInfo.specifiedQueryInfo.queryInterval &&
(et - st) < (int64_t)g_queryInfo.specifiedQueryInfo.queryInterval) { (et - st) < (int64_t)g_queryInfo.specifiedQueryInfo.queryInterval) {
taosMsleep(g_queryInfo.specifiedQueryInfo.queryInterval - taosMsleep((int32_t)(g_queryInfo.specifiedQueryInfo.queryInterval -
(et - st)); // ms (et - st))); // ms
} }
st = taosGetTimestampMs(); st = taosGetTimestampMs();
...@@ -157,20 +157,19 @@ void *superTableQuery(void *sarg) { ...@@ -157,20 +157,19 @@ void *superTableQuery(void *sarg) {
while (queryTimes--) { while (queryTimes--) {
if (g_queryInfo.superQueryInfo.queryInterval && if (g_queryInfo.superQueryInfo.queryInterval &&
(et - st) < (int64_t)g_queryInfo.superQueryInfo.queryInterval) { (et - st) < (int64_t)g_queryInfo.superQueryInfo.queryInterval) {
taosMsleep(g_queryInfo.superQueryInfo.queryInterval - taosMsleep((int32_t)(g_queryInfo.superQueryInfo.queryInterval -
(et - st)); // ms (et - st))); // ms
// printf("========sleep duration:%"PRId64 "========inserted // printf("========sleep duration:%"PRId64 "========inserted
// rows:%d, table range:%d - %d\n", (1000 - (et - st)), i, // rows:%d, table range:%d - %d\n", (1000 - (et - st)), i,
// pThreadInfo->start_table_from, pThreadInfo->end_table_to); // pThreadInfo->start_table_from, pThreadInfo->end_table_to);
} }
st = taosGetTimestampMs(); st = taosGetTimestampMs();
for (int i = pThreadInfo->start_table_from; for (int i = (int)pThreadInfo->start_table_from;
i <= pThreadInfo->end_table_to; i++) { i <= pThreadInfo->end_table_to; i++) {
for (int j = 0; j < g_queryInfo.superQueryInfo.sqlCount; j++) { for (int j = 0; j < g_queryInfo.superQueryInfo.sqlCount; j++) {
memset(sqlstr, 0, BUFFER_SIZE); memset(sqlstr, 0, BUFFER_SIZE) replaceChildTblName(
replaceChildTblName(g_queryInfo.superQueryInfo.sql[j], sqlstr, g_queryInfo.superQueryInfo.sql[j], sqlstr, i);
i);
if (g_queryInfo.superQueryInfo.result[j][0] != '\0') { if (g_queryInfo.superQueryInfo.result[j][0] != '\0') {
sprintf(pThreadInfo->filePath, "%s-%d", sprintf(pThreadInfo->filePath, "%s-%d",
g_queryInfo.superQueryInfo.result[j], g_queryInfo.superQueryInfo.result[j],
...@@ -257,7 +256,7 @@ int queryTestProcess() { ...@@ -257,7 +256,7 @@ int queryTestProcess() {
for (int j = 0; j < nConcurrent; j++) { for (int j = 0; j < nConcurrent; j++) {
uint64_t seq = i * nConcurrent + j; uint64_t seq = i * nConcurrent + j;
threadInfo *pThreadInfo = infos + seq; threadInfo *pThreadInfo = infos + seq;
pThreadInfo->threadID = seq; pThreadInfo->threadID = (int)seq;
pThreadInfo->querySeq = i; pThreadInfo->querySeq = i;
if (0 == strncasecmp(g_queryInfo.queryMode, "taosc", 5)) { if (0 == strncasecmp(g_queryInfo.queryMode, "taosc", 5)) {
...@@ -337,7 +336,7 @@ int queryTestProcess() { ...@@ -337,7 +336,7 @@ int queryTestProcess() {
int64_t a = ntables / threads; int64_t a = ntables / threads;
if (a < 1) { if (a < 1) {
threads = ntables; threads = (int)ntables;
a = 1; a = 1;
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册