mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-25 04:02:41 +01:00
Update the emacs mode to recognize fadd, fsum, fmul, fdiv, frem, fcmp, icmp
llvm-svn: 169064
This commit is contained in:
parent
17e71f21a8
commit
5f2988f933
@ -5,7 +5,6 @@
|
||||
;; Create mode-specific tables.
|
||||
(defvar llvm-mode-syntax-table nil
|
||||
"Syntax table used while in LLVM mode.")
|
||||
|
||||
(defvar llvm-font-lock-keywords
|
||||
(list
|
||||
;; Comments
|
||||
@ -35,8 +34,10 @@
|
||||
;; Arithmetic and Logical Operators
|
||||
`(,(regexp-opt '("add" "sub" "mul" "div" "rem" "and" "or" "xor"
|
||||
"setne" "seteq" "setlt" "setgt" "setle" "setge") 'words) . font-lock-keyword-face)
|
||||
;; Floating-point operators
|
||||
`(,(regexp-opt '("fadd" "fsub" "fmul" "fdiv" "frem") 'words) . font-lock-keyword-face)
|
||||
;; Special instructions
|
||||
`(,(regexp-opt '("phi" "tail" "call" "cast" "select" "to" "shl" "shr" "vaarg" "vanext") 'words) . font-lock-keyword-face)
|
||||
`(,(regexp-opt '("phi" "tail" "call" "cast" "select" "to" "shl" "shr" "fcmp" "icmp" "vaarg" "vanext") 'words) . font-lock-keyword-face)
|
||||
;; Control instructions
|
||||
`(,(regexp-opt '("ret" "br" "switch" "invoke" "unwind" "unreachable") 'words) . font-lock-keyword-face)
|
||||
;; Memory operators
|
||||
@ -111,7 +112,7 @@
|
||||
(interactive)
|
||||
(kill-all-local-variables)
|
||||
(use-local-map llvm-mode-map) ; Provides the local keymap.
|
||||
(setq major-mode 'llvm-mode)
|
||||
(setq major-mode 'llvm-mode)
|
||||
|
||||
(make-local-variable 'font-lock-defaults)
|
||||
(setq major-mode 'llvm-mode ; This is how describe-mode
|
||||
|
Loading…
Reference in New Issue
Block a user