如何检查我的 Perl 安装是 32 位还是 64 位? [英] How can I check whether my Perl installation is 32 or 64 bit?

查看:37
本文介绍了如何检查我的 Perl 安装是 32 位还是 64 位?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在 Windows 上,如何检查我的 Perl 安装是 32 位还是 64 位?

On Windows, how can I check whether my Perl installation is 32 or 64 bit?

推荐答案

如果要检查它使用的是 32 位整数还是 64 位整数,请使用以下内容:

If you want to check if it uses 32-bit integers or 64-bit integers, use the following:

perl -V:ivsize      # use Config; say $Config{ivsize}

  • 如果返回值为 4,则您的 Perl 使用 32 位整数.
  • 如果返回值为 8,则您的 Perl 使用 64 位整数.
  • 另见:对MAX_INT 的 perl 等价物是什么?"的回答

    如果要检查它使用的是 32 位指针还是 64 位指针,请使用以下命令:

    If you want to check if it uses 32-bit pointers or 64-bit pointers, use the following:

    perl -V:ptrsize     # use Config; say $Config{ptrsize}
    

    • 如果返回值为 4,则您的 Perl 可以处理 4 GiB 的 RAM.
    • 如果返回值为 8,则您的 Perl 可以寻址无限"RAM.
    • 如果要检查它是 32 位程序还是 64 位程序,请使用以下命令:

      If you want to check if it's a 32-bit program or a 64-bit program, use the following:

      perl -V:archname    # use Config; say $Config{archname}
      

      • 如果返回值包含 x86_64,则为 64 位进程.
      • 如果返回值包含 x86(但不包含 x86_64),则为 32 位进程.
        • If the returned value includes x86_64, it's a 64-bit process.
        • If the returned value includes x86 (but not x86_64), it's a 32-bit process.
        • 这个值也包含在 perl -v 的输出中.

          This value is also included in the output of perl -v.

          注意:您不应该检查 use64bitintuse64bitall,因为它们指示传递给 Configure 的参数,而不是提供有关什么的信息实际正在使用中.

          Note: You shouldn't be checking use64bitint or use64bitall as these indicate what parameters were passed to Configure rather than provide information about what is actually being used.

          这篇关于如何检查我的 Perl 安装是 32 位还是 64 位?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆