]> git.alsa-project.org Git - alsa-lib.git/commit
pcm: remove alloca() from softvol_load_control()
authorTakashi Sakamoto <o-takashi@sakamocchi.jp>
Thu, 14 Jul 2016 14:07:37 +0000 (23:07 +0900)
committerTakashi Iwai <tiwai@suse.de>
Thu, 14 Jul 2016 14:33:50 +0000 (16:33 +0200)
commit349920f93dc6e8be54e0fa21a0b2a31a412ccc1e
treeae0509ed21b42b5c97683b7e8c85913b18d2a458
parent8306bb2b6a68c2fdfa406ac07091309e8e65041c
pcm: remove alloca() from softvol_load_control()

Both of alloca() and automatic variables keeps storages on stack, while
the former generates more instructions than the latter. It's better to use
the latter if the size of storage is computable at pre-compile or compile
time; i.e. just for structures.

This commit obsolete usages of alloca() with automatic variables.

Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
src/pcm/pcm_softvol.c