Merge branch 'dev'
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 64d3204..835bec7 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1,6 +1,6 @@
 cmake_minimum_required(VERSION 2.6...3.0.2)
 
-project(xbyak LANGUAGES CXX VERSION 6.60.2)
+project(xbyak LANGUAGES CXX VERSION 6.61)
 
 file(GLOB headers xbyak/*.h)
 
diff --git a/doc/changelog.md b/doc/changelog.md
index b52fe26..93d23d9 100644
--- a/doc/changelog.md
+++ b/doc/changelog.md
@@ -1,5 +1,6 @@
 # History
 
+* 2022/Jul/29 ver 6.61 fix exception of movzx eax, ah in 64-bit mode
 * 2022/Jun/16 ver 6.60.2 fix detection of GFNI, VAES, and VPCLMULQDQ
 * 2022/Jun/15 ver 6.60.1 fix link error of Xbyak::util::Cpu on Visual Studio with /O0 option
 * 2022/Jun/06 ver 6.60 change the version format to avoid it going backward
diff --git a/meson.build b/meson.build
index 5685857..73282e1 100644
--- a/meson.build
+++ b/meson.build
@@ -5,7 +5,7 @@
 project(
 	'xbyak',
 	'cpp',
-	version: '6.60.2',
+	version: '6.61',
 	license: 'BSD-3-Clause',
 	default_options: 'b_ndebug=if-release'
 )
diff --git a/readme.md b/readme.md
index 986bda1..69ef3c2 100644
--- a/readme.md
+++ b/readme.md
@@ -1,5 +1,5 @@
 
-# Xbyak 6.60.2 [![Badge Build]][Build Status]
+# Xbyak 6.61 [![Badge Build]][Build Status]
 
 *A C++ JIT assembler for x86 (IA32), x64 (AMD64, x86-64)*
 
diff --git a/readme.txt b/readme.txt
index 442a10f..14c1ffb 100644
--- a/readme.txt
+++ b/readme.txt
@@ -1,5 +1,5 @@
 

-    C++用x86(IA-32), x64(AMD64, x86-64) JITアセンブラ Xbyak 6.60.2

+    C++用x86(IA-32), x64(AMD64, x86-64) JITアセンブラ Xbyak 6.61

 

 -----------------------------------------------------------------------------

 ◎概要

@@ -400,6 +400,7 @@
 -----------------------------------------------------------------------------

 ◎履歴

 

+2022/07/29 ver 6.61 movzx eax, ahがエラーになるのを修正

 2022/06/16 ver 6.60.2 GFNI, VAES, VPCLMULQDQの判定修正

 2022/06/15 ver 6.60.1 Visual Studio /O0でXbyak::util::Cpuがリンクエラーになるのに対応

 2022/06/06 ver 6.60 バージョンのつけ方を数値が戻らないように変更

diff --git a/test/make_nm.cpp b/test/make_nm.cpp
index 5cfd441..801ffe0 100644
--- a/test/make_nm.cpp
+++ b/test/make_nm.cpp
@@ -1317,6 +1317,7 @@
 				put(p, REG64, REG16|REG8|MEM8|MEM16);
 				put(p, REG32, REG16|REG8|MEM8|MEM16);
 				put(p, REG16, REG8|MEM8);
+				put(p, "eax, ah");
 			}
 		}
 #ifdef XBYAK64
diff --git a/xbyak/xbyak.h b/xbyak/xbyak.h
index fd89a46..eecea61 100644
--- a/xbyak/xbyak.h
+++ b/xbyak/xbyak.h
@@ -77,7 +77,11 @@
 	#endif
 	#include <windows.h>
 	#include <malloc.h>
-	#define XBYAK_TLS __declspec(thread)
+	#ifdef _MSC_VER
+		#define XBYAK_TLS __declspec(thread)
+	#else
+		#define XBYAK_TLS __thread
+	#endif
 #elif defined(__GNUC__)
 	#include <unistd.h>
 	#include <sys/mman.h>
@@ -144,7 +148,7 @@
 
 enum {
 	DEFAULT_MAX_CODE_SIZE = 4096,
-	VERSION = 0x6602 /* 0xABCD = A.BC(.D) */
+	VERSION = 0x6610 /* 0xABCD = A.BC(.D) */
 };
 
 #ifndef MIE_INTEGER_TYPE_DEFINED
@@ -2187,9 +2191,6 @@
 	{
 		if (op.isBit(32)) XBYAK_THROW(ERR_BAD_COMBINATION)
 		int w = op.isBit(16);
-#ifdef XBYAK64
-		if (op.isHigh8bit()) XBYAK_THROW(ERR_BAD_COMBINATION)
-#endif
 		bool cond = reg.isREG() && (reg.getBit() > op.getBit());
 		opModRM(reg, op, cond && op.isREG(), cond && op.isMEM(), 0x0F, code | w);
 	}
diff --git a/xbyak/xbyak_mnemonic.h b/xbyak/xbyak_mnemonic.h
index 4e19bd3..5871557 100644
--- a/xbyak/xbyak_mnemonic.h
+++ b/xbyak/xbyak_mnemonic.h
@@ -1,4 +1,4 @@
-const char *getVersionString() const { return "6.60.2"; }
+const char *getVersionString() const { return "6.61"; }
 void adc(const Operand& op, uint32_t imm) { opRM_I(op, imm, 0x10, 2); }
 void adc(const Operand& op1, const Operand& op2) { opRM_RM(op1, op2, 0x10); }
 void adcx(const Reg32e& reg, const Operand& op) { opGen(reg, op, 0xF6, 0x66, isREG32_REG32orMEM, NONE, 0x38); }