Benjamin Kramer
f50125ecaa
DAGCombine add (sext i1), X into sub X, (zext i1) if sext from i1 is illegal. The latter usually compiles into smaller code.
example code:
unsigned foo(unsigned x, unsigned y) {
if (x != 0) y--;
return y;
}
before:
_foo: ## @foo
cmpl $1, 4(%esp) ## encoding: [0x83,0x7c,0x24,0x04,0x01]
sbbl %eax, %eax ## encoding: [0x19,0xc0]
notl %eax ## encoding: [0xf7,0xd0]
addl 8(%esp), %eax ## encoding: [0x03,0x44,0x24,0x08]
ret ## encoding: [0xc3]
after:
_foo: ## @foo
cmpl $1, 4(%esp) ## encoding: [0x83,0x7c,0x24,0x04,0x01]
movl 8(%esp), %eax ## encoding: [0x8b,0x44,0x24,0x08]
adcl $-1, %eax ## encoding: [0x83,0xd0,0xff]
ret ## encoding: [0xc3]
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122455 91177308-0d34-0410-b5e6-96231b3b80d8
2010-12-22 23:17:45 +00:00
..
2010-08-05 15:45:33 +00:00
2010-10-08 03:57:25 +00:00
2010-03-14 22:31:16 +00:00
2010-03-02 18:56:03 +00:00
2010-02-12 10:34:29 +00:00
2010-07-15 22:07:12 +00:00
2010-02-25 19:00:39 +00:00
2010-06-24 15:04:11 +00:00
2010-02-09 06:41:03 +00:00
2010-06-21 22:17:20 +00:00
2010-03-25 05:40:48 +00:00
2010-03-14 18:51:18 +00:00
2010-02-09 06:41:03 +00:00
2010-02-12 10:34:29 +00:00
2010-10-01 00:16:17 +00:00
2010-05-02 15:36:26 +00:00
2010-05-02 15:36:26 +00:00
2010-09-30 23:57:10 +00:00
2010-05-02 15:36:26 +00:00
2010-09-30 23:57:10 +00:00
2010-09-30 23:57:10 +00:00
2010-05-02 15:36:26 +00:00
2010-02-10 22:58:57 +00:00
2010-06-24 15:04:11 +00:00
2010-06-24 20:14:51 +00:00
2010-02-12 10:34:29 +00:00
2010-06-15 21:58:33 +00:00
2010-09-30 20:51:52 +00:00
2010-06-15 21:58:33 +00:00
2010-02-18 21:33:05 +00:00
2010-05-29 02:23:39 +00:00
2010-06-24 15:24:03 +00:00
2010-01-17 19:09:12 +00:00
2010-09-30 23:57:10 +00:00
2010-06-24 15:24:03 +00:00
2010-06-15 21:58:33 +00:00
2010-05-27 23:57:25 +00:00
2010-06-15 21:58:33 +00:00
2010-09-19 21:58:55 +00:00
2010-04-28 08:30:49 +00:00
2010-03-14 22:31:16 +00:00
2010-08-05 17:04:15 +00:00
2010-09-30 23:57:10 +00:00
2010-06-24 15:24:03 +00:00
2010-09-30 23:57:10 +00:00
2010-06-15 21:58:33 +00:00
2010-06-28 22:09:45 +00:00
2010-10-19 18:58:51 +00:00
2010-04-17 16:29:15 +00:00
2010-12-19 20:12:58 +00:00
2010-06-15 21:58:33 +00:00
2010-01-23 06:17:14 +00:00
2010-03-30 22:47:00 +00:00
2010-08-05 17:04:15 +00:00
2010-03-01 18:30:58 +00:00
2010-10-20 22:03:58 +00:00
2010-09-03 03:24:08 +00:00
2010-09-03 03:24:08 +00:00
2010-08-18 20:32:46 +00:00
2010-06-15 21:58:33 +00:00
2010-07-02 20:16:09 +00:00
2010-04-28 08:30:49 +00:00
2010-11-27 20:43:02 +00:00
2010-04-15 04:31:42 +00:00
2010-05-07 17:03:48 +00:00
2010-05-07 17:03:48 +00:00
2010-10-01 04:17:55 +00:00
2010-12-19 20:12:58 +00:00
2010-09-30 23:57:10 +00:00
2010-03-10 03:07:41 +00:00
2010-05-07 17:03:48 +00:00
2010-07-01 21:55:59 +00:00
2010-02-06 09:07:11 +00:00
2010-01-21 02:09:26 +00:00
2010-02-03 21:39:04 +00:00
2010-04-17 16:29:15 +00:00
2010-04-17 16:29:15 +00:00
2010-11-27 20:43:02 +00:00
2010-05-03 22:36:46 +00:00
2010-04-17 16:29:15 +00:00
2010-08-15 20:42:56 +00:00
2010-01-19 19:45:51 +00:00
2010-08-05 20:25:37 +00:00
2010-02-01 22:40:09 +00:00
2010-02-04 18:46:28 +00:00
2010-02-05 01:27:11 +00:00
2010-02-16 20:50:18 +00:00
2010-02-13 02:06:10 +00:00
2010-02-15 22:03:29 +00:00
2010-06-23 18:16:24 +00:00
2010-02-27 07:36:59 +00:00
2010-02-24 00:39:35 +00:00
2010-02-23 22:44:02 +00:00
2010-02-23 22:43:58 +00:00
2010-03-04 20:42:07 +00:00
2010-03-05 21:49:10 +00:00
2010-03-05 21:49:13 +00:00
2010-06-18 01:24:29 +00:00
2010-04-14 20:56:09 +00:00
2010-12-06 22:39:26 +00:00
2010-04-08 20:02:37 +00:00
2010-04-13 18:50:27 +00:00
2010-04-21 20:57:54 +00:00
2010-09-30 23:57:10 +00:00
2010-04-29 23:47:46 +00:00
2010-09-22 05:49:14 +00:00
2010-05-03 22:40:32 +00:00
2010-06-15 21:58:33 +00:00
2010-06-15 21:58:33 +00:00
2010-05-07 21:35:53 +00:00
2010-05-10 19:03:57 +00:00
2010-05-12 18:46:03 +00:00
2010-05-21 00:52:33 +00:00
2010-09-21 20:50:32 +00:00
2010-05-26 23:55:23 +00:00
2010-05-26 17:55:45 +00:00
2010-08-05 20:25:37 +00:00
2010-08-05 20:25:37 +00:00
2010-06-09 20:05:00 +00:00
2010-06-15 19:08:40 +00:00
2010-06-15 16:20:57 +00:00
2010-06-24 23:45:15 +00:00
2010-06-28 20:01:15 +00:00
2010-06-25 20:48:10 +00:00
2010-07-14 23:12:52 +00:00
2010-06-28 19:31:15 +00:00
2010-06-28 22:09:45 +00:00
2010-07-02 20:16:09 +00:00
2010-07-02 20:36:18 +00:00
2010-07-13 18:14:47 +00:00
2010-07-06 23:06:58 +00:00
2010-07-16 04:45:35 +00:00
2010-07-13 20:17:05 +00:00
2010-07-15 18:45:27 +00:00
2010-07-30 06:44:31 +00:00
2010-08-04 22:40:58 +00:00
2010-08-04 23:36:02 +00:00
2010-08-12 00:17:38 +00:00
2010-09-01 22:15:35 +00:00
2010-09-16 18:30:55 +00:00
2010-12-02 23:29:58 +00:00
2010-09-20 20:39:59 +00:00
2010-09-30 19:44:31 +00:00
2010-10-11 21:08:42 +00:00
2010-11-02 17:01:30 +00:00
2010-11-09 16:22:27 +00:00
2010-11-18 20:05:18 +00:00
2010-12-02 21:32:30 +00:00
2010-09-22 05:49:14 +00:00
2010-12-19 22:08:31 +00:00
2010-12-22 23:17:45 +00:00
2010-02-15 20:47:49 +00:00
2010-12-06 15:35:15 +00:00
2010-01-25 07:43:40 +00:00
2010-04-28 19:58:07 +00:00
2010-10-10 23:11:06 +00:00
2010-05-28 01:14:11 +00:00
2010-05-28 01:14:11 +00:00
2010-03-03 00:35:56 +00:00
2010-10-13 17:14:25 +00:00
2010-11-30 09:23:54 +00:00
2010-04-28 08:30:49 +00:00
2010-11-29 22:34:55 +00:00
2010-04-17 16:29:15 +00:00
2010-12-10 00:26:57 +00:00
2010-08-12 02:06:36 +00:00
2010-10-28 00:35:54 +00:00
2010-12-19 22:08:31 +00:00
2010-07-22 02:48:34 +00:00
2010-07-22 02:48:34 +00:00
2010-12-19 20:12:58 +00:00
2010-01-16 23:37:33 +00:00
2010-09-22 22:58:22 +00:00
2010-04-17 16:29:15 +00:00
2010-07-12 20:46:04 +00:00
2010-01-19 06:39:54 +00:00
2010-11-13 19:54:30 +00:00
2010-04-01 06:04:33 +00:00
2010-10-12 23:47:58 +00:00
2010-08-04 15:31:35 +00:00
2010-02-06 03:28:46 +00:00
2010-08-05 17:04:15 +00:00
2010-08-05 17:04:15 +00:00
2010-08-05 17:04:15 +00:00
2010-03-14 22:31:16 +00:00
2010-10-08 05:12:30 +00:00
2010-03-25 05:40:48 +00:00
2010-02-18 21:25:53 +00:00
2010-02-06 09:07:11 +00:00
2010-12-14 21:34:53 +00:00
2010-09-20 22:52:00 +00:00
2010-11-09 01:15:07 +00:00
2010-12-21 21:41:44 +00:00
2010-08-18 20:32:46 +00:00
2010-04-17 16:29:15 +00:00
2010-04-27 19:38:45 +00:00
2010-06-26 00:39:23 +00:00
2010-07-07 20:33:27 +00:00
2010-12-19 04:58:57 +00:00
2010-08-18 20:32:46 +00:00
2010-12-19 20:12:58 +00:00
2010-04-28 01:39:28 +00:00
2010-12-21 21:55:50 +00:00
2010-09-22 05:49:14 +00:00
2010-08-30 10:48:29 +00:00
2010-09-22 05:49:14 +00:00
2010-09-03 03:24:08 +00:00
2010-07-16 22:51:10 +00:00
2010-07-15 22:07:12 +00:00
2010-05-16 09:08:45 +00:00
2010-05-16 09:08:45 +00:00
2010-07-20 15:52:32 +00:00
2010-09-17 20:24:24 +00:00
2010-10-01 04:17:55 +00:00
2010-08-21 02:32:36 +00:00
2010-04-17 16:29:15 +00:00
2010-07-16 02:01:19 +00:00
2010-09-05 02:18:34 +00:00
2010-07-16 02:01:19 +00:00
2010-07-10 22:42:12 +00:00
2010-07-10 09:00:22 +00:00
2010-02-12 15:28:40 +00:00
2010-04-17 03:43:36 +00:00
2010-10-23 09:06:59 +00:00
2010-04-17 16:29:15 +00:00
2010-08-05 23:57:43 +00:00
2010-05-08 04:47:54 +00:00
2010-11-06 21:37:06 +00:00
2010-06-15 21:58:33 +00:00
2010-05-21 18:17:54 +00:00
2010-02-12 10:34:29 +00:00
2010-03-30 22:47:00 +00:00
2010-03-11 00:22:57 +00:00
2010-09-22 05:49:14 +00:00
2010-08-30 18:12:35 +00:00
2010-04-28 08:30:49 +00:00
2010-06-14 20:19:03 +00:00
2010-01-20 07:11:32 +00:00
2010-07-10 16:30:25 +00:00
2010-07-10 16:30:25 +00:00
2010-07-10 16:30:25 +00:00
2010-07-10 16:30:25 +00:00
2010-11-18 00:50:20 +00:00
2010-07-02 20:16:09 +00:00
2010-04-28 08:30:49 +00:00
2010-06-24 15:04:11 +00:00
2010-08-05 17:04:15 +00:00
2010-12-19 20:12:58 +00:00
2010-08-23 19:39:25 +00:00
2010-07-02 20:16:09 +00:00
2010-05-06 00:05:37 +00:00
2010-07-08 22:38:02 +00:00
2010-12-19 20:12:58 +00:00
2010-08-18 20:32:46 +00:00
2010-03-25 05:40:48 +00:00
2010-06-15 21:58:33 +00:00
2010-08-27 01:30:14 +00:00
2010-04-17 16:29:15 +00:00
2010-04-17 16:29:15 +00:00
2010-09-02 03:45:58 +00:00
2010-06-24 15:24:03 +00:00
2010-04-17 16:29:15 +00:00
2010-02-12 10:34:29 +00:00
2010-02-12 10:34:29 +00:00
2010-02-12 10:34:29 +00:00
2010-06-05 00:33:07 +00:00
2010-07-15 15:14:45 +00:00
2010-08-17 22:50:37 +00:00
2010-06-04 00:14:48 +00:00
2010-06-04 19:16:34 +00:00
2010-07-20 17:06:20 +00:00
2010-02-17 01:08:57 +00:00
2010-03-05 03:08:23 +00:00
2010-09-30 20:51:52 +00:00
2010-08-24 15:55:12 +00:00
2010-08-29 14:49:42 +00:00
2010-12-15 22:16:21 +00:00
2010-06-25 20:48:10 +00:00
2010-08-19 18:33:29 +00:00
2010-02-12 10:34:29 +00:00
2010-05-18 21:42:03 +00:00
2010-05-18 17:22:24 +00:00
2010-10-07 20:56:25 +00:00
2010-04-08 07:37:57 +00:00
2010-05-31 17:30:14 +00:00
2010-11-18 01:35:23 +00:00
2010-09-22 05:49:14 +00:00
2010-04-02 19:36:14 +00:00
2010-09-22 05:49:14 +00:00
2010-11-18 01:35:23 +00:00
2010-09-30 23:57:10 +00:00
2010-09-30 23:57:10 +00:00
2010-09-30 23:57:10 +00:00
2010-09-30 23:57:10 +00:00
2010-10-05 21:58:12 +00:00
2010-10-01 04:17:55 +00:00
2010-10-01 05:08:18 +00:00
2010-10-01 21:39:35 +00:00
2010-09-30 23:57:10 +00:00
2010-09-30 23:57:10 +00:00
2010-10-01 04:17:55 +00:00
2010-10-01 04:17:55 +00:00
2010-09-22 05:49:14 +00:00
2010-11-02 23:01:44 +00:00
2010-11-02 23:01:44 +00:00
2010-11-03 18:08:41 +00:00
2010-04-08 05:57:57 +00:00
2010-02-05 23:21:31 +00:00
2010-12-22 08:02:57 +00:00
2010-01-19 23:30:49 +00:00
2010-05-28 17:06:30 +00:00
2010-06-22 23:32:47 +00:00
2010-04-21 00:19:28 +00:00
2010-04-04 19:28:59 +00:00
2010-09-30 20:51:52 +00:00
2010-09-30 20:51:52 +00:00
2010-03-11 08:20:21 +00:00
2010-06-15 21:58:33 +00:00
2010-04-17 16:29:15 +00:00
2010-09-22 05:49:14 +00:00
2010-03-30 18:49:01 +00:00
2010-03-30 18:49:01 +00:00
2010-12-04 20:32:23 +00:00
2010-03-25 20:01:07 +00:00
2010-09-30 20:51:52 +00:00
2010-02-11 23:55:29 +00:00
2010-09-30 20:51:52 +00:00
2010-02-18 21:33:05 +00:00
2010-03-03 04:36:42 +00:00
2010-09-17 22:28:18 +00:00
2010-08-17 22:17:24 +00:00
2010-03-10 07:07:45 +00:00
2010-02-13 00:31:44 +00:00
2010-02-13 00:31:44 +00:00
2010-11-19 21:49:38 +00:00
2010-06-03 20:21:33 +00:00
2010-04-28 08:30:49 +00:00
2010-02-22 22:43:23 +00:00
2010-01-21 02:09:26 +00:00
2010-01-20 07:19:19 +00:00
2010-04-28 01:53:13 +00:00
2010-04-28 01:53:13 +00:00
2010-12-19 20:12:58 +00:00
2010-12-22 23:09:28 +00:00
2010-02-06 09:07:11 +00:00
2010-10-01 05:36:09 +00:00
2010-04-28 01:53:13 +00:00
2010-07-23 21:08:12 +00:00
2010-04-29 05:08:22 +00:00
2010-09-22 05:49:14 +00:00
2010-07-14 06:44:01 +00:00
2010-12-02 20:17:34 +00:00
2010-09-30 22:02:06 +00:00
2010-09-20 22:52:00 +00:00
2010-04-01 08:25:26 +00:00
2010-01-23 06:02:43 +00:00
2010-08-28 17:28:30 +00:00
2010-08-29 03:19:04 +00:00
2010-10-07 20:50:20 +00:00
2010-12-19 22:08:31 +00:00
2010-03-19 20:04:42 +00:00
2010-03-30 22:47:00 +00:00
2010-05-07 17:03:48 +00:00
2010-03-30 23:12:48 +00:00
2010-06-25 21:05:35 +00:00
2010-07-15 22:07:12 +00:00
2010-06-21 22:17:20 +00:00
2010-07-06 05:18:56 +00:00
2010-10-25 22:17:05 +00:00
2010-08-30 10:48:29 +00:00
2010-09-19 21:58:55 +00:00
2010-02-28 20:36:49 +00:00
2010-10-01 05:36:09 +00:00
2010-01-19 21:51:51 +00:00
2010-06-24 02:06:24 +00:00
2010-02-09 06:41:03 +00:00
2010-11-22 09:45:38 +00:00
2010-02-09 06:41:03 +00:00
2010-09-30 20:51:52 +00:00
2010-02-08 20:34:14 +00:00
2010-08-28 00:51:03 +00:00
2010-03-14 03:48:46 +00:00
2010-09-22 05:49:14 +00:00
2010-09-23 06:55:34 +00:00
2010-06-21 22:17:20 +00:00
2010-09-22 04:39:11 +00:00
2010-04-28 08:30:49 +00:00
2010-11-27 20:43:02 +00:00
2010-12-09 06:25:53 +00:00
2010-12-09 00:27:58 +00:00
2010-02-27 07:36:59 +00:00
2010-09-02 03:45:51 +00:00
2010-10-05 17:24:05 +00:00
2010-12-05 07:30:36 +00:00
2010-09-22 05:49:14 +00:00
2010-12-02 23:29:58 +00:00
2010-04-05 19:17:22 +00:00
2010-03-05 06:17:43 +00:00
2010-08-25 22:49:25 +00:00
2010-06-22 20:54:03 +00:00
2010-06-22 20:54:03 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-03-30 22:47:00 +00:00
2010-12-19 20:12:58 +00:00
2010-03-24 20:49:50 +00:00
2010-09-30 23:57:10 +00:00
2010-08-18 20:32:46 +00:00
2010-10-01 21:39:35 +00:00
2010-08-28 17:59:08 +00:00
2010-02-27 23:53:53 +00:00
2010-03-31 00:40:13 +00:00
2010-09-19 21:58:55 +00:00
2010-03-24 20:49:50 +00:00
2010-07-28 00:21:48 +00:00
2010-03-02 07:50:03 +00:00
2010-08-18 20:32:46 +00:00
2010-08-18 20:32:46 +00:00
2010-08-25 01:47:16 +00:00
2010-12-20 00:54:26 +00:00
2010-12-19 20:12:58 +00:00
2010-04-07 22:53:17 +00:00
2010-09-09 18:48:34 +00:00
2010-03-24 20:49:50 +00:00
2010-04-17 16:29:15 +00:00
2010-09-30 23:57:10 +00:00
2010-03-31 00:40:13 +00:00
2010-12-18 14:23:57 +00:00
2010-12-19 20:12:58 +00:00
2010-06-01 18:35:14 +00:00
2010-05-28 17:06:30 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-12-19 20:12:58 +00:00
2010-10-08 19:24:18 +00:00
2010-10-03 22:52:07 +00:00
2010-10-03 22:02:38 +00:00
2010-12-20 20:10:50 +00:00
2010-12-21 21:55:50 +00:00
2010-07-08 07:36:46 +00:00
2010-03-26 02:13:13 +00:00
2010-04-28 08:30:49 +00:00
2010-08-18 20:32:46 +00:00
2010-06-09 20:30:22 +00:00
2010-02-10 02:17:34 +00:00