support/ab.c:881: error: INTEGER_OVERFLOW_L2
  ([-oo, 9223372036854775807] + 500):signed64.

support/ab.c:796:9: <LHS trace>
794.         apr_time_t totalcon = 0, total = 0, totald = 0, totalwait = 0;
795.         apr_time_t meancon, meantot, meand, meanwait;
796.         apr_interval_time_t mincon = AB_MAX, mintot = AB_MAX, mind = AB_MAX,
             ^
797.                             minwait = AB_MAX;
798.         apr_interval_time_t maxcon = 0, maxtot = 0, maxd = 0, maxwait = 0;

support/ab.c:796:9: Assignment
794.         apr_time_t totalcon = 0, total = 0, totald = 0, totalwait = 0;
795.         apr_time_t meancon, meantot, meand, meanwait;
796.         apr_interval_time_t mincon = AB_MAX, mintot = AB_MAX, mind = AB_MAX,
             ^
797.                             minwait = AB_MAX;
798.         apr_interval_time_t maxcon = 0, maxtot = 0, maxd = 0, maxwait = 0;

support/ab.c:881:9: Binary operation: ([-oo, 9223372036854775807] + 500):signed64
879.          * Reduce stats from apr time to milliseconds
880.          */
881.         mincon     = ap_round_ms(mincon);
             ^
882.         mind       = ap_round_ms(mind);
883.         minwait    = ap_round_ms(minwait);

static void output_results(int sig)
{
    double timetaken;
    if (sig) {
        lasttime = apr_time_now();
    }
    timetaken = (double) (lasttime - start) / APR_USEC_PER_SEC;
    printf("\n\n");
    printf("Server Software:        %s\n", servername);
    printf("Server Hostname:        %s\n", hostname);
    printf("Server Port:            %hu\n", port);
#ifdef USE_SSL
    if (is_ssl && ssl_info) {
        printf("SSL/TLS Protocol:       %s\n", ssl_info);
    }
#endif
    printf("\n");
    printf("Document Path:          %s\n", path);
    printf("Document Length:        %" APR_SIZE_T_FMT " bytes\n", doclen);
    printf("\n");
    printf("Concurrency Level:      %d\n", concurrency);
    printf("Time taken for tests:   %.3f seconds\n", timetaken);
    printf("Complete requests:      %d\n", done);
    printf("Failed requests:        %d\n", bad);
    if (bad)
        printf("   (Connect: %d, Receive: %d, Length: %d, Exceptions: %d)\n",
            err_conn, err_recv, err_length, err_except);
    printf("Write errors:           %d\n", epipe);
    if (err_response)
        printf("Non-2xx responses:      %d\n", err_response);
    if (keepalive)
        printf("Keep-Alive requests:    %d\n", doneka);
    printf("Total transferred:      %" APR_INT64_T_FMT " bytes\n", totalread);
    if (posting > 0)
        printf("Total POSTed:           %" APR_INT64_T_FMT "\n", totalposted);
    printf("HTML transferred:       %" APR_INT64_T_FMT " bytes\n", totalbread);
    if (timetaken && done) {
        printf("Requests per second:    %.2f [#/sec] (mean)\n",
               (double) done / timetaken);
        printf("Time per request:       %.3f [ms] (mean)\n",
               (double) concurrency * timetaken * 1000 / done);
        printf("Time per request:       %.3f [ms] (mean, across all concurrent requests)\n",
               (double) timetaken * 1000 / done);
        printf("Transfer rate:          %.2f [Kbytes/sec] received\n",
               (double) totalread / 1024 / timetaken);
        if (posting > 0) {
            printf("                        %.2f kb/s sent\n",
               (double) totalposted / timetaken / 1024);
            printf("                        %.2f kb/s total\n",
               (double) (totalread + totalposted) / timetaken / 1024);
        }
    }
    if (done > 0) {
        int i;
        apr_time_t totalcon = 0, total = 0, totald = 0, totalwait = 0;
        apr_time_t meancon, meantot, meand, meanwait;
        apr_interval_time_t mincon = AB_MAX, mintot = AB_MAX, mind = AB_MAX,
                            minwait = AB_MAX;
        apr_interval_time_t maxcon = 0, maxtot = 0, maxd = 0, maxwait = 0;
        apr_interval_time_t mediancon = 0, mediantot = 0, mediand = 0, medianwait = 0;
        double sdtot = 0, sdcon = 0, sdd = 0, sdwait = 0;
        for (i = 0; i < done; i++) {
            struct data *s = &stats[i];
            mincon = ap_min(mincon, s->ctime);
            mintot = ap_min(mintot, s->time);
            mind = ap_min(mind, s->time - s->ctime);
            minwait = ap_min(minwait, s->waittime);
            maxcon = ap_max(maxcon, s->ctime);
            maxtot = ap_max(maxtot, s->time);
            maxd = ap_max(maxd, s->time - s->ctime);
            maxwait = ap_max(maxwait, s->waittime);
            totalcon += s->ctime;
            total += s->time;
            totald += s->time - s->ctime;
            totalwait += s->waittime;
        }
        meancon = totalcon / done;
        meantot = total / done;
        meand = totald / done;
        meanwait = totalwait / done;
        for (i = 0; i < done; i++) {
            struct data *s = &stats[i];
            double a;
            a = ((double)s->time - meantot);
            sdtot += a * a;
            a = ((double)s->ctime - meancon);
            sdcon += a * a;
            a = ((double)s->time - (double)s->ctime - meand);
            sdd += a * a;
            a = ((double)s->waittime - meanwait);
            sdwait += a * a;
        }
        sdtot = (done > 1) ? sqrt(sdtot / (done - 1)) : 0;
        sdcon = (done > 1) ? sqrt(sdcon / (done - 1)) : 0;
        sdd = (done > 1) ? sqrt(sdd / (done - 1)) : 0;
        sdwait = (done > 1) ? sqrt(sdwait / (done - 1)) : 0;
        qsort(stats, done, sizeof(struct data),
              (int (*) (const void *, const void *)) compradre);
        if ((done > 1) && (done % 2))
            mediancon = (stats[done / 2].ctime + stats[done / 2 + 1].ctime) / 2;
        else
            mediancon = stats[done / 2].ctime;
        qsort(stats, done, sizeof(struct data),
              (int (*) (const void *, const void *)) compri);
        if ((done > 1) && (done % 2))
            mediand = (stats[done / 2].time + stats[done / 2 + 1].time \
            -stats[done / 2].ctime - stats[done / 2 + 1].ctime) / 2;
        else
            mediand = stats[done / 2].time - stats[done / 2].ctime;
        qsort(stats, done, sizeof(struct data),
              (int (*) (const void *, const void *)) compwait);
        if ((done > 1) && (done % 2))
            medianwait = (stats[done / 2].waittime + stats[done / 2 + 1].waittime) / 2;
        else
            medianwait = stats[done / 2].waittime;
        qsort(stats, done, sizeof(struct data),
              (int (*) (const void *, const void *)) comprando);
        if ((done > 1) && (done % 2))
            mediantot = (stats[done / 2].time + stats[done / 2 + 1].time) / 2;
        else
            mediantot = stats[done / 2].time;
        printf("\nConnection Times (ms)\n");
        mincon     = ap_round_ms(mincon);
        mind       = ap_round_ms(mind);
        minwait    = ap_round_ms(minwait);
        mintot     = ap_round_ms(mintot);
        meancon    = ap_round_ms(meancon);
        meand      = ap_round_ms(meand);
        meanwait   = ap_round_ms(meanwait);
        meantot    = ap_round_ms(meantot);
        mediancon  = ap_round_ms(mediancon);
        mediand    = ap_round_ms(mediand);
        medianwait = ap_round_ms(medianwait);
        mediantot  = ap_round_ms(mediantot);
        maxcon     = ap_round_ms(maxcon);
        maxd       = ap_round_ms(maxd);
        maxwait    = ap_round_ms(maxwait);
        maxtot     = ap_round_ms(maxtot);
        sdcon      = ap_double_ms(sdcon);
        sdd        = ap_double_ms(sdd);
        sdwait     = ap_double_ms(sdwait);
        sdtot      = ap_double_ms(sdtot);
        if (confidence) {
#define CONF_FMT_STRING "%5" APR_TIME_T_FMT " %4" APR_TIME_T_FMT " %5.1f %6" APR_TIME_T_FMT " %7" APR_TIME_T_FMT "\n"
            printf("              min  mean[+/-sd] median   max\n");
            printf("Connect:    " CONF_FMT_STRING,
                   mincon, meancon, sdcon, mediancon, maxcon);
            printf("Processing: " CONF_FMT_STRING,
                   mind, meand, sdd, mediand, maxd);
            printf("Waiting:    " CONF_FMT_STRING,
                   minwait, meanwait, sdwait, medianwait, maxwait);
            printf("Total:      " CONF_FMT_STRING,
                   mintot, meantot, sdtot, mediantot, maxtot);
#undef CONF_FMT_STRING
#define     SANE(what,mean,median,sd) \
              { \
                double d = (double)mean - median; \
                if (d < 0) d = -d; \
                if (d > 2 * sd ) \
                    printf("ERROR: The median and mean for " what " are more than twice the standard\n" \
                           "       deviation apart. These results are NOT reliable.\n"); \
                else if (d > sd ) \
                    printf("WARNING: The median and mean for " what " are not within a normal deviation\n" \
                           "        These results are probably not that reliable.\n"); \
            }
            SANE("the initial connection time", meancon, mediancon, sdcon);
            SANE("the processing time", meand, mediand, sdd);
            SANE("the waiting time", meanwait, medianwait, sdwait);
            SANE("the total time", meantot, mediantot, sdtot);
        }
        else {
            printf("              min   avg   max\n");
#define CONF_FMT_STRING "%5" APR_TIME_T_FMT " %5" APR_TIME_T_FMT "%5" APR_TIME_T_FMT "\n"
            printf("Connect:    " CONF_FMT_STRING, mincon, meancon, maxcon);
            printf("Processing: " CONF_FMT_STRING, mintot - mincon,
                                                   meantot - meancon,
                                                   maxtot - maxcon);
            printf("Total:      " CONF_FMT_STRING, mintot, meantot, maxtot);
#undef CONF_FMT_STRING
        }
        if (percentile && (done > 1)) {
            printf("\nPercentage of the requests served within a certain time (ms)\n");
            for (i = 0; i < sizeof(percs) / sizeof(int); i++) {
                if (percs[i] <= 0)
                    printf(" 0%%  <0> (never)\n");
                else if (percs[i] >= 100)
                    printf(" 100%%  %5" APR_TIME_T_FMT " (longest request)\n",
                           ap_round_ms(stats[done - 1].time));
                else
                    printf("  %d%%  %5" APR_TIME_T_FMT "\n", percs[i],
                           ap_round_ms(stats[(int) (done * percs[i] / 100)].time));
            }
        }
        if (csvperc) {
            FILE *out = fopen(csvperc, "w");
            if (!out) {
                perror("Cannot open CSV output file");
                exit(1);
            }
            fprintf(out, "" "Percentage served" "," "Time in ms" "\n");
            for (i = 0; i < 100; i++) {
                double t;
                if (i == 0)
                    t = ap_double_ms(stats[0].time);
                else if (i == 100)
                    t = ap_double_ms(stats[done - 1].time);
                else
                    t = ap_double_ms(stats[(int) (0.5 + done * i / 100.0)].time);
                fprintf(out, "%d,%.3f\n", i, t);
            }
            fclose(out);
        }
        if (gnuplot) {
            FILE *out = fopen(gnuplot, "w");
            char tmstring[APR_CTIME_LEN];
            if (!out) {
                perror("Cannot open gnuplot output file");
                exit(1);
            }
            fprintf(out, "starttime\tseconds\tctime\tdtime\tttime\twait\n");
            for (i = 0; i < done; i++) {
                (void) apr_ctime(tmstring, stats[i].starttime);
                fprintf(out, "%s\t%" APR_TIME_T_FMT "\t%" APR_TIME_T_FMT
                               "\t%" APR_TIME_T_FMT "\t%" APR_TIME_T_FMT
                               "\t%" APR_TIME_T_FMT "\n", tmstring,
                        apr_time_sec(stats[i].starttime),
                        ap_round_ms(stats[i].ctime),
                        ap_round_ms(stats[i].time - stats[i].ctime),
                        ap_round_ms(stats[i].time),
                        ap_round_ms(stats[i].waittime));
            }
            fclose(out);
        }
    }
    if (sig) {
        exit(1);
    }
}
['static void output_results(int sig)\n{\n    double timetaken;\n    if (sig) {\n        lasttime = apr_time_now();\n    }\n    timetaken = (double) (lasttime - start) / APR_USEC_PER_SEC;\n    printf("\\n\\n");\n    printf("Server Software:        %s\\n", servername);\n    printf("Server Hostname:        %s\\n", hostname);\n    printf("Server Port:            %hu\\n", port);\n#ifdef USE_SSL\n    if (is_ssl && ssl_info) {\n        printf("SSL/TLS Protocol:       %s\\n", ssl_info);\n    }\n#endif\n    printf("\\n");\n    printf("Document Path:          %s\\n", path);\n    printf("Document Length:        %" APR_SIZE_T_FMT " bytes\\n", doclen);\n    printf("\\n");\n    printf("Concurrency Level:      %d\\n", concurrency);\n    printf("Time taken for tests:   %.3f seconds\\n", timetaken);\n    printf("Complete requests:      %d\\n", done);\n    printf("Failed requests:        %d\\n", bad);\n    if (bad)\n        printf("   (Connect: %d, Receive: %d, Length: %d, Exceptions: %d)\\n",\n            err_conn, err_recv, err_length, err_except);\n    printf("Write errors:           %d\\n", epipe);\n    if (err_response)\n        printf("Non-2xx responses:      %d\\n", err_response);\n    if (keepalive)\n        printf("Keep-Alive requests:    %d\\n", doneka);\n    printf("Total transferred:      %" APR_INT64_T_FMT " bytes\\n", totalread);\n    if (posting > 0)\n        printf("Total POSTed:           %" APR_INT64_T_FMT "\\n", totalposted);\n    printf("HTML transferred:       %" APR_INT64_T_FMT " bytes\\n", totalbread);\n    if (timetaken && done) {\n        printf("Requests per second:    %.2f [#/sec] (mean)\\n",\n               (double) done / timetaken);\n        printf("Time per request:       %.3f [ms] (mean)\\n",\n               (double) concurrency * timetaken * 1000 / done);\n        printf("Time per request:       %.3f [ms] (mean, across all concurrent requests)\\n",\n               (double) timetaken * 1000 / done);\n        printf("Transfer rate:          %.2f [Kbytes/sec] received\\n",\n               (double) totalread / 1024 / timetaken);\n        if (posting > 0) {\n            printf("                        %.2f kb/s sent\\n",\n               (double) totalposted / timetaken / 1024);\n            printf("                        %.2f kb/s total\\n",\n               (double) (totalread + totalposted) / timetaken / 1024);\n        }\n    }\n    if (done > 0) {\n        int i;\n        apr_time_t totalcon = 0, total = 0, totald = 0, totalwait = 0;\n        apr_time_t meancon, meantot, meand, meanwait;\n        apr_interval_time_t mincon = AB_MAX, mintot = AB_MAX, mind = AB_MAX,\n                            minwait = AB_MAX;\n        apr_interval_time_t maxcon = 0, maxtot = 0, maxd = 0, maxwait = 0;\n        apr_interval_time_t mediancon = 0, mediantot = 0, mediand = 0, medianwait = 0;\n        double sdtot = 0, sdcon = 0, sdd = 0, sdwait = 0;\n        for (i = 0; i < done; i++) {\n            struct data *s = &stats[i];\n            mincon = ap_min(mincon, s->ctime);\n            mintot = ap_min(mintot, s->time);\n            mind = ap_min(mind, s->time - s->ctime);\n            minwait = ap_min(minwait, s->waittime);\n            maxcon = ap_max(maxcon, s->ctime);\n            maxtot = ap_max(maxtot, s->time);\n            maxd = ap_max(maxd, s->time - s->ctime);\n            maxwait = ap_max(maxwait, s->waittime);\n            totalcon += s->ctime;\n            total += s->time;\n            totald += s->time - s->ctime;\n            totalwait += s->waittime;\n        }\n        meancon = totalcon / done;\n        meantot = total / done;\n        meand = totald / done;\n        meanwait = totalwait / done;\n        for (i = 0; i < done; i++) {\n            struct data *s = &stats[i];\n            double a;\n            a = ((double)s->time - meantot);\n            sdtot += a * a;\n            a = ((double)s->ctime - meancon);\n            sdcon += a * a;\n            a = ((double)s->time - (double)s->ctime - meand);\n            sdd += a * a;\n            a = ((double)s->waittime - meanwait);\n            sdwait += a * a;\n        }\n        sdtot = (done > 1) ? sqrt(sdtot / (done - 1)) : 0;\n        sdcon = (done > 1) ? sqrt(sdcon / (done - 1)) : 0;\n        sdd = (done > 1) ? sqrt(sdd / (done - 1)) : 0;\n        sdwait = (done > 1) ? sqrt(sdwait / (done - 1)) : 0;\n        qsort(stats, done, sizeof(struct data),\n              (int (*) (const void *, const void *)) compradre);\n        if ((done > 1) && (done % 2))\n            mediancon = (stats[done / 2].ctime + stats[done / 2 + 1].ctime) / 2;\n        else\n            mediancon = stats[done / 2].ctime;\n        qsort(stats, done, sizeof(struct data),\n              (int (*) (const void *, const void *)) compri);\n        if ((done > 1) && (done % 2))\n            mediand = (stats[done / 2].time + stats[done / 2 + 1].time \\\n            -stats[done / 2].ctime - stats[done / 2 + 1].ctime) / 2;\n        else\n            mediand = stats[done / 2].time - stats[done / 2].ctime;\n        qsort(stats, done, sizeof(struct data),\n              (int (*) (const void *, const void *)) compwait);\n        if ((done > 1) && (done % 2))\n            medianwait = (stats[done / 2].waittime + stats[done / 2 + 1].waittime) / 2;\n        else\n            medianwait = stats[done / 2].waittime;\n        qsort(stats, done, sizeof(struct data),\n              (int (*) (const void *, const void *)) comprando);\n        if ((done > 1) && (done % 2))\n            mediantot = (stats[done / 2].time + stats[done / 2 + 1].time) / 2;\n        else\n            mediantot = stats[done / 2].time;\n        printf("\\nConnection Times (ms)\\n");\n        mincon     = ap_round_ms(mincon);\n        mind       = ap_round_ms(mind);\n        minwait    = ap_round_ms(minwait);\n        mintot     = ap_round_ms(mintot);\n        meancon    = ap_round_ms(meancon);\n        meand      = ap_round_ms(meand);\n        meanwait   = ap_round_ms(meanwait);\n        meantot    = ap_round_ms(meantot);\n        mediancon  = ap_round_ms(mediancon);\n        mediand    = ap_round_ms(mediand);\n        medianwait = ap_round_ms(medianwait);\n        mediantot  = ap_round_ms(mediantot);\n        maxcon     = ap_round_ms(maxcon);\n        maxd       = ap_round_ms(maxd);\n        maxwait    = ap_round_ms(maxwait);\n        maxtot     = ap_round_ms(maxtot);\n        sdcon      = ap_double_ms(sdcon);\n        sdd        = ap_double_ms(sdd);\n        sdwait     = ap_double_ms(sdwait);\n        sdtot      = ap_double_ms(sdtot);\n        if (confidence) {\n#define CONF_FMT_STRING "%5" APR_TIME_T_FMT " %4" APR_TIME_T_FMT " %5.1f %6" APR_TIME_T_FMT " %7" APR_TIME_T_FMT "\\n"\n            printf("              min  mean[+/-sd] median   max\\n");\n            printf("Connect:    " CONF_FMT_STRING,\n                   mincon, meancon, sdcon, mediancon, maxcon);\n            printf("Processing: " CONF_FMT_STRING,\n                   mind, meand, sdd, mediand, maxd);\n            printf("Waiting:    " CONF_FMT_STRING,\n                   minwait, meanwait, sdwait, medianwait, maxwait);\n            printf("Total:      " CONF_FMT_STRING,\n                   mintot, meantot, sdtot, mediantot, maxtot);\n#undef CONF_FMT_STRING\n#define     SANE(what,mean,median,sd) \\\n              { \\\n                double d = (double)mean - median; \\\n                if (d < 0) d = -d; \\\n                if (d > 2 * sd ) \\\n                    printf("ERROR: The median and mean for " what " are more than twice the standard\\n" \\\n                           "       deviation apart. These results are NOT reliable.\\n"); \\\n                else if (d > sd ) \\\n                    printf("WARNING: The median and mean for " what " are not within a normal deviation\\n" \\\n                           "        These results are probably not that reliable.\\n"); \\\n            }\n            SANE("the initial connection time", meancon, mediancon, sdcon);\n            SANE("the processing time", meand, mediand, sdd);\n            SANE("the waiting time", meanwait, medianwait, sdwait);\n            SANE("the total time", meantot, mediantot, sdtot);\n        }\n        else {\n            printf("              min   avg   max\\n");\n#define CONF_FMT_STRING "%5" APR_TIME_T_FMT " %5" APR_TIME_T_FMT "%5" APR_TIME_T_FMT "\\n"\n            printf("Connect:    " CONF_FMT_STRING, mincon, meancon, maxcon);\n            printf("Processing: " CONF_FMT_STRING, mintot - mincon,\n                                                   meantot - meancon,\n                                                   maxtot - maxcon);\n            printf("Total:      " CONF_FMT_STRING, mintot, meantot, maxtot);\n#undef CONF_FMT_STRING\n        }\n        if (percentile && (done > 1)) {\n            printf("\\nPercentage of the requests served within a certain time (ms)\\n");\n            for (i = 0; i < sizeof(percs) / sizeof(int); i++) {\n                if (percs[i] <= 0)\n                    printf(" 0%%  <0> (never)\\n");\n                else if (percs[i] >= 100)\n                    printf(" 100%%  %5" APR_TIME_T_FMT " (longest request)\\n",\n                           ap_round_ms(stats[done - 1].time));\n                else\n                    printf("  %d%%  %5" APR_TIME_T_FMT "\\n", percs[i],\n                           ap_round_ms(stats[(int) (done * percs[i] / 100)].time));\n            }\n        }\n        if (csvperc) {\n            FILE *out = fopen(csvperc, "w");\n            if (!out) {\n                perror("Cannot open CSV output file");\n                exit(1);\n            }\n            fprintf(out, "" "Percentage served" "," "Time in ms" "\\n");\n            for (i = 0; i < 100; i++) {\n                double t;\n                if (i == 0)\n                    t = ap_double_ms(stats[0].time);\n                else if (i == 100)\n                    t = ap_double_ms(stats[done - 1].time);\n                else\n                    t = ap_double_ms(stats[(int) (0.5 + done * i / 100.0)].time);\n                fprintf(out, "%d,%.3f\\n", i, t);\n            }\n            fclose(out);\n        }\n        if (gnuplot) {\n            FILE *out = fopen(gnuplot, "w");\n            char tmstring[APR_CTIME_LEN];\n            if (!out) {\n                perror("Cannot open gnuplot output file");\n                exit(1);\n            }\n            fprintf(out, "starttime\\tseconds\\tctime\\tdtime\\tttime\\twait\\n");\n            for (i = 0; i < done; i++) {\n                (void) apr_ctime(tmstring, stats[i].starttime);\n                fprintf(out, "%s\\t%" APR_TIME_T_FMT "\\t%" APR_TIME_T_FMT\n                               "\\t%" APR_TIME_T_FMT "\\t%" APR_TIME_T_FMT\n                               "\\t%" APR_TIME_T_FMT "\\n", tmstring,\n                        apr_time_sec(stats[i].starttime),\n                        ap_round_ms(stats[i].ctime),\n                        ap_round_ms(stats[i].time - stats[i].ctime),\n                        ap_round_ms(stats[i].time),\n                        ap_round_ms(stats[i].waittime));\n            }\n            fclose(out);\n        }\n    }\n    if (sig) {\n        exit(1);\n    }\n}']