I KNOW this is not an Emacs bug.  Eli Zaretskii suggested I report it as one.

I never invoke a Perl program with a line like

    perl -w myscript.pl

Rather I go into the Perl directory and type the name of the program.  The program I run in a DOS window are exactly the same one I run in Emacs shell.

Here is a simple one called oneline.pl:

    use 5.012;
    use strict;
    #$|=1;

    my $line = <STDIN>;
    print "\$line = $line\n";

In a DOS window it runs like this:

    C:\Perl>oneline.pl
    1234
    $line = 1234

    C:\Perl>

Note in DOS I type in the line 1234, and the program prints "$line = 1234".

In Emacs shell mode it runs like this:

    c:\Perl>oneline.pl
    oneline.pl
    $line =

    c:\Perl>

In Emacs the program doesn't pause to wait for a keyboard input.  It blows right through it and then prints "$line = ".

The -w switch is not involved.