From: Lu Guanqun Date: Wed, 10 Apr 2013 08:11:53 +0000 (+0800) Subject: add disassembler support for message gateway X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=45c9d0c00fc213d668275f3fe16af6b409134d75;p=contrib%2Fbeignet.git add disassembler support for message gateway Signed-off-by: Lu Guanqun Reviewed-by: Zhigang Gong --- diff --git a/backend/src/backend/gen/gen_mesa_disasm.c b/backend/src/backend/gen/gen_mesa_disasm.c index 9cdc581..6d9bf7f 100644 --- a/backend/src/backend/gen/gen_mesa_disasm.c +++ b/backend/src/backend/gen/gen_mesa_disasm.c @@ -310,6 +310,17 @@ static const char *target_function_gen6[16] = { [GEN_SFID_DATAPORT_DATA_CACHE] = "data" }; +static const char *gateway_sub_function[8] = { + [0] = "open gateway", + [1] = "close gateway", + [2] = "forward gateway", + [3] = "get time stamp", + [4] = "barrier", + [5] = "update gateway state", + [6] = "MMIO R/W", + [7] = "reserved" +}; + static const char *math_function[16] = { [GEN_MATH_FUNCTION_INV] = "inv", [GEN_MATH_FUNCTION_LOG] = "log", @@ -1106,6 +1117,12 @@ int gen_disasm (FILE *file, const void *opaque_insn) inst->bits3.gen7_untyped_rw.simd_mode, inst->bits3.gen7_untyped_rw.msg_type); break; + case GEN_SFID_MESSAGE_GATEWAY: + format (file, " (subfunc: %s, notify: %d, ackreq: %d)", + gateway_sub_function[inst->bits3.gen7_msg_gw.subfunc], + inst->bits3.gen7_msg_gw.notify, + inst->bits3.gen7_msg_gw.ackreq); + break; default: format (file, "unsupported target %d", target); diff --git a/backend/src/backend/gen_defs.hpp b/backend/src/backend/gen_defs.hpp index f7428b2..187224a 100644 --- a/backend/src/backend/gen_defs.hpp +++ b/backend/src/backend/gen_defs.hpp @@ -778,6 +778,20 @@ struct GenInstruction uint32_t pad1:2; } da3src; + /*! Message gateway */ + struct { + uint32_t subfunc:3; + uint32_t pad:11; + uint32_t ackreq:1; + uint32_t notify:2; + uint32_t pad2:2; + uint32_t header_present:1; + uint32_t response_length:5; + uint32_t msg_length:4; + uint32_t pad3:2; + uint32_t end_of_thread:1; + } gen7_msg_gw; + int d; uint32_t ud; float f;