rename pipe_llvm_program_header to pipe_binary_program_header
authorKarol Herbst <kherbst@redhat.com>
Sat, 11 May 2019 12:26:06 +0000 (14:26 +0200)
committerKarol Herbst <karolherbst@gmail.com>
Sat, 21 Sep 2019 08:28:32 +0000 (08:28 +0000)
We want to use it for other formats as well, so give it a more generic name

Signed-off-by: Karol Herbst <kherbst@redhat.com>
Reviewed-by: Francisco Jerez <currojerez@riseup.net>
Reviewed-by: Pierre Moreau <pierre.morrow@free.fr>
src/gallium/drivers/r600/evergreen_compute.c
src/gallium/drivers/radeonsi/si_compute.c
src/gallium/include/pipe/p_state.h
src/gallium/state_trackers/clover/llvm/codegen/common.cpp
src/gallium/state_trackers/clover/spirv/invocation.cpp

index 0f6c5c2f2ff2b0c611fe21816faafedfdd109cfb..419738eec7029f560a030950af7a4e59374a24a7 100644 (file)
@@ -429,7 +429,7 @@ static void *evergreen_create_compute_state(struct pipe_context *ctx,
        struct r600_context *rctx = (struct r600_context *)ctx;
        struct r600_pipe_compute *shader = CALLOC_STRUCT(r600_pipe_compute);
 #ifdef HAVE_OPENCL
-       const struct pipe_llvm_program_header *header;
+       const struct pipe_binary_program_header *header;
        void *p;
        boolean use_kill;
 #endif
index 037b1927189a8387a9f1f599b4e043a075872e55..9fe2bb5cf4b7680f3f936df0e35321fc10fa31ef 100644 (file)
@@ -256,7 +256,7 @@ static void *si_create_compute_state(
                                            &sel->compiler_ctx_state,
                                            program, si_create_compute_state_async);
        } else {
-               const struct pipe_llvm_program_header *header;
+               const struct pipe_binary_program_header *header;
                header = cso->prog;
 
                program->shader.binary.elf_size = header->num_bytes;
index 4b23824f3de3b6e4263aaf4f415918ebdb5954ad..b0d8eaed2fa90714c380835cf382ae23ab0f2fee 100644 (file)
@@ -879,9 +879,9 @@ struct pipe_grid_info
 };
 
 /**
- * Structure used as a header for serialized LLVM programs.
+ * Structure used as a header for serialized compute programs.
  */
-struct pipe_llvm_program_header
+struct pipe_binary_program_header
 {
    uint32_t num_bytes; /**< Number of bytes in the LLVM bytecode program. */
    char blob[];
index 98a9d5ffb5ed6a0257a101873c4913cc72d375cc..3879fb61a02702b9e5aa2d0dc65c8307fb604c23 100644 (file)
@@ -177,7 +177,7 @@ namespace {
 
    module::section
    make_text_section(const std::vector<char> &code) {
-      const pipe_llvm_program_header header { uint32_t(code.size()) };
+      const pipe_binary_program_header header { uint32_t(code.size()) };
       module::section text { 0, module::section::text_executable,
                              header.num_bytes, {} };
 
index 86916117b4892cd5d11e2aa8563ab673f699dc3d..620c6b1e0ea57a38bb1bd9382d62772f838bf266 100644 (file)
@@ -95,7 +95,7 @@ namespace {
    module::section
    make_text_section(const std::vector<char> &code,
                      enum module::section::type section_type) {
-      const pipe_llvm_program_header header { uint32_t(code.size()) };
+      const pipe_binary_program_header header { uint32_t(code.size()) };
       module::section text { 0, section_type, header.num_bytes, {} };
 
       text.data.insert(text.data.end(), reinterpret_cast<const char *>(&header),
@@ -625,7 +625,7 @@ clover::spirv::link_program(const std::vector<module> &modules,
                          sec.type == module::section::text_library;
                }, mod.secs);
 
-      const auto c_il = ((struct pipe_llvm_program_header*)msec.data.data())->blob;
+      const auto c_il = ((struct pipe_binary_program_header*)msec.data.data())->blob;
       const auto length = msec.size;
 
       sections.push_back(reinterpret_cast<const uint32_t *>(c_il));