Hannu Krosing <han...@google.com> writes: > At least "does it run" tests should be there -
> For example with the current toolchain on MacOS I was able to compile > __builtin_readcyclecounter(); but it crashed when the result was > executed. > The same code compiled *and run* fine on same laptop with Ubuntu 24.04 > We might also want to have some testing about available speedups from > pg_bitmanip.h being used, but that could be tricky to test in an > universal way. Keep in mind that pg_test_timing is not just some random exercise in a vacuum. The point of it IMV is to provide data about the performance one can expect from the instr_time.h infrastructure, which bears on what kind of resolution EXPLAIN ANALYZE and other features have. So if we did want to depend on read_tsc() or __builtin_readcyclecounter() or what-have-you, the way to go about it would be to change instr_time.h to compile code that uses that. I would consider that to be a separate patch from what we're doing to pg_test_timing here. regards, tom lane