[LLVMdev] Can the FileCheck ignore spaces ?

42 views
Skip to first unread message

Shawn

unread,
Mar 15, 2013, 4:16:00 AM3/15/13
to llv...@cs.uiuc.edu, Zhang Yu
Hi all:
I'm writing testcase for the MC layer regression in llvm, the
disassembled string is a bit complicate, for example:
"IALU.T0 (I0) = BIU0.DM ; REPEAT AT ( 2 ) ;;"
The spaces in the disassembled string is error-prone. Is there any
option to tell the FileCheck utility to ignore the spaces ?

Kind Regards.

Shawn.

_______________________________________________
LLVM Developers mailing list
LLV...@cs.uiuc.edu http://llvm.cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev

杨勇勇

unread,
Mar 15, 2013, 8:15:34 AM3/15/13
to Shawn, Zhang Yu, llv...@cs.uiuc.edu
http://llvm.org/docs/CommandGuide/FileCheck.html
says FileCheck ignores white spaces/tabs by default unless you use
"--strict-whitespace" option.

2013/3/15 Shawn <shaol...@ia.ac.cn>:


> Hi all:
> I'm writing testcase for the MC layer regression in llvm, the
> disassembled string is a bit complicate, for example:
> "IALU.T0 (I0) = BIU0.DM ; REPEAT AT ( 2 ) ;;"
> The spaces in the disassembled string is error-prone. Is there any
> option to tell the FileCheck utility to ignore the spaces ?
>
> Kind Regards.
>
> Shawn.
>

--
杨勇勇 (Yang Yong-Yong)

杨勇勇

unread,
Mar 15, 2013, 8:22:06 AM3/15/13
to Shawn, Zhang Yu, llv...@cs.uiuc.edu
http://llvm.org/docs/CommandGuide/FileCheck.html
says FileCheck ignores white spaces/tabs by default unless you use
"--strict-whitespace" option.

2013/3/15 Shawn <shaol...@ia.ac.cn>:


> Hi all:
> I'm writing testcase for the MC layer regression in llvm, the
> disassembled string is a bit complicate, for example:
> "IALU.T0 (I0) = BIU0.DM ; REPEAT AT ( 2 ) ;;"
> The spaces in the disassembled string is error-prone. Is there any
> option to tell the FileCheck utility to ignore the spaces ?
>
> Kind Regards.
>
> Shawn.
>

--
杨勇勇 (Yang Yong-Yong)

Shawn

unread,
Mar 16, 2013, 12:26:17 AM3/16/13
to 杨勇勇, Zhang Yu, llv...@cs.uiuc.edu
"--strict-whitespace

By default, FileCheck canonicalizes input horizontal whitespace (spaces and tabs) which causes it to ignore these differences (a space will match a tab). The --strict-whitespace argument disables this behavior. End-of-line sequences are canonicalized to UNIX-style ‘n’ in all modes."

So it just ignore the differences between space and tab, not the whitespace .



On 2013年03月15日 20:15, 杨勇勇 wrote:
http://llvm.org/docs/CommandGuide/FileCheck.html
says FileCheck ignores white spaces/tabs by default unless you use
"--strict-whitespace" option.

2013/3/15 Shawn <shaol...@ia.ac.cn>:
Hi all:
    I'm writing testcase for the MC layer regression  in llvm, the
disassembled string is a bit complicate, for example:
    "IALU.T0 (I0) = BIU0.DM ; REPEAT AT ( 2 ) ;;"
    The spaces in the disassembled string is error-prone. Is there any
option to tell the FileCheck utility to ignore the spaces ?

     Kind Regards.

Shawn.





-- 
============================
中国科学院自动化研究所 谢少林
电话: 010-62620080-777

杨勇勇

unread,
Mar 16, 2013, 3:35:50 AM3/16/13
to Shawn, Zhang Yu, llv...@cs.uiuc.edu
2013/3/16 Shawn <shaol...@ia.ac.cn>:

> "--strict-whitespace
>
> By default, FileCheck canonicalizes input horizontal whitespace (spaces and
> tabs) which causes it to ignore these differences (a space will match a
> tab). The --strict-whitespace argument disables this behavior. End-of-line
> sequences are canonicalized to UNIX-style ‘n’ in all modes."
>
> So it just ignore the differences between space and tab, not the whitespace

I guess a whitespace means a space or a tab. Filecheck treats tabs and
spaces equally, and ignores differences between "whitespace" strings.

> .
>
>
>
> On 2013年03月15日 20:15, 杨勇勇 wrote:
>
> http://llvm.org/docs/CommandGuide/FileCheck.html
> says FileCheck ignores white spaces/tabs by default unless you use
> "--strict-whitespace" option.
>
> 2013/3/15 Shawn <shaol...@ia.ac.cn>:
>
> Hi all:
> I'm writing testcase for the MC layer regression in llvm, the
> disassembled string is a bit complicate, for example:
> "IALU.T0 (I0) = BIU0.DM ; REPEAT AT ( 2 ) ;;"
> The spaces in the disassembled string is error-prone. Is there any
> option to tell the FileCheck utility to ignore the spaces ?
>
> Kind Regards.
>
> Shawn.
>
>
>
>
>
> --
> ============================
> 中国科学院自动化研究所 谢少林
> 电话: 010-62620080-777

--

Reply all
Reply to author
Forward
0 new messages