After I started to use <bits/stdc++.h>
and C++11
my compiler is slowing down. Compilation finishes around 3secs. Is there any way to speed up? I use Ubuntu and Geany. [Sorry for bad English...]
№ | Пользователь | Рейтинг |
---|---|---|
1 | tourist | 4009 |
2 | jiangly | 3823 |
3 | Benq | 3738 |
4 | Radewoosh | 3633 |
5 | jqdai0815 | 3620 |
6 | orzdevinwang | 3529 |
7 | ecnerwala | 3446 |
8 | Um_nik | 3396 |
9 | ksun48 | 3390 |
10 | gamegame | 3386 |
Страны | Города | Организации | Всё → |
№ | Пользователь | Вклад |
---|---|---|
1 | cry | 167 |
2 | Um_nik | 163 |
3 | maomao90 | 162 |
3 | atcoder_official | 162 |
5 | adamant | 159 |
6 | -is-this-fft- | 158 |
7 | awoo | 157 |
8 | TheScrasse | 154 |
9 | Dominater069 | 153 |
9 | nor | 153 |
After I started to use <bits/stdc++.h>
and C++11
my compiler is slowing down. Compilation finishes around 3secs. Is there any way to speed up? I use Ubuntu and Geany. [Sorry for bad English...]
Название |
---|
"There is no way to speed up compilation time" from the above comment is not correct. Many people use
<bits/stdc++.h>
, but few know the real purpose for this file: it is not there to save typing, it is there to save compilation time.By using
stdc++.h
, you can create a precompiled header file that includes the whole standard library. Next time you run the compiler, it does not need to parse the standard library headers again — it just reads the precompiled header file instead.You can read how to create and use the precompiled header here: https://gcc.gnu.org/onlinedocs/libstdc++/manual/using_headers.html#manual.intro.using.headers.pre. After this, compilation time of an empty program should be significantly reduced.