diff options
author | Matt Turner <[email protected]> | 2017-07-06 21:19:18 -0700 |
---|---|---|
committer | Matt Turner <[email protected]> | 2017-08-29 15:20:57 -0700 |
commit | 9fdbc273efdf20f325f9711997ae77016f3d4e0a (patch) | |
tree | ad6292e6f127b931afa1788d84bf40e457214eab /src | |
parent | cdbaa8a12feff2286b61cecf0b2e5b3feb8d902d (diff) |
intel/isl: Remove 'inline' keywords
Unless you have data, the compiler knows better than you whether a
function should be inlined.
Unlike all other cases in this series, the removal of the inline keyword
from isl_format_has_channel_type actually changes the resulting binary
with gcc-6.3.0:
text data bss dec hex filename
7831116 346384 420648 8598148 833284 i965_dri.so before
7830716 346384 420648 8597748 8330f4 i965_dri.so after
I think this is likely an improvement. No difference in the resulting
binary with clang-4.0.
Reviewed-by: Emil Velikov <[email protected]>
Reviewed-by: Eric Engestrom <[email protected]>
Diffstat (limited to 'src')
-rw-r--r-- | src/intel/isl/isl_emit_depth_stencil.c | 2 | ||||
-rw-r--r-- | src/intel/isl/isl_format.c | 2 | ||||
-rw-r--r-- | src/intel/isl/isl_surface_state.c | 4 |
3 files changed, 4 insertions, 4 deletions
diff --git a/src/intel/isl/isl_emit_depth_stencil.c b/src/intel/isl/isl_emit_depth_stencil.c index 0af04786f30..90ce8893e5b 100644 --- a/src/intel/isl/isl_emit_depth_stencil.c +++ b/src/intel/isl/isl_emit_depth_stencil.c @@ -26,7 +26,7 @@ #define __gen_address_type uint64_t #define __gen_user_data void -static inline uint64_t +static uint64_t __gen_combine_address(void *data, void *loc, uint64_t addr, uint32_t delta) { return addr + delta; diff --git a/src/intel/isl/isl_format.c b/src/intel/isl/isl_format.c index 435b0d003a6..fba3ac5e1ac 100644 --- a/src/intel/isl/isl_format.c +++ b/src/intel/isl/isl_format.c @@ -608,7 +608,7 @@ isl_formats_are_ccs_e_compatible(const struct gen_device_info *devinfo, fmtl1->channels.a.bits == fmtl2->channels.a.bits; } -static inline bool +static bool isl_format_has_channel_type(enum isl_format fmt, enum isl_base_type type) { const struct isl_format_layout *fmtl = isl_format_get_layout(fmt); diff --git a/src/intel/isl/isl_surface_state.c b/src/intel/isl/isl_surface_state.c index 61cd4c69fc9..df6e69d75fd 100644 --- a/src/intel/isl/isl_surface_state.c +++ b/src/intel/isl/isl_surface_state.c @@ -26,7 +26,7 @@ #define __gen_address_type uint64_t #define __gen_user_data void -static inline uint64_t +static uint64_t __gen_combine_address(void *data, void *loc, uint64_t addr, uint32_t delta) { return addr + delta; @@ -130,7 +130,7 @@ get_surftype(enum isl_surf_dim dim, isl_surf_usage_flags_t usage) * hardware. Note that this does NOT give you the actual hardware enum values * but an index into the isl_to_gen_[hv]align arrays above. */ -static inline struct isl_extent3d +static struct isl_extent3d get_image_alignment(const struct isl_surf *surf) { if (GEN_GEN >= 9) { |