Building on Ted's answer, I would actually do something like this (untested):
my_pch.h:
#include <bits/stdc++.h> // might need to specify the full path here
And then:
g++ -O3 -std=c++20 -pedantic-errors -o pch/bits/my_pch.h.gch my_pch.h
And finally, your program would look like this:
#include "my_pch.h"
int main() {
// ...
}
This means you don't need to put #include <bits/stdc++.h> directly in your source files, since that is a bit naughty. It also means you can add other include files to my_pch.h if you want them.
I think, also, it wouldn't cost you anything to put, say, #include <string> after including my_pch.h, and that doing that sort of thing might be wise. If you're ever going to move the code into production you could then recompile it with my_pch.h empty.
Edit: Another thing to consider (which I also can't test) is just to include the things you actually use (string, vector, whatever) in my_pch.h. That will probably pull in bits/stdc++.h anyway, when building the precompiled header. Make it a comprehensive list so that you don't need to have to keep adding to it. Then you have portable code and people won't keep beating you up about it.