<?xml version="1.0"?>
<ownershipDocument>

    <schemaVersion>X0508</schemaVersion>

    <documentType>4</documentType>

    <periodOfReport>2024-02-21</periodOfReport>

    <issuer>
        <issuerCik>0001159167</issuerCik>
        <issuerName>IROBOT CORP</issuerName>
        <issuerTradingSymbol>IRBT</issuerTradingSymbol>
    </issuer>

    <reportingOwner>
        <reportingOwnerId>
            <rptOwnerCik>0001810721</rptOwnerCik>
            <rptOwnerName>Wong Karian</rptOwnerName>
        </reportingOwnerId>
        <reportingOwnerAddress>
            <rptOwnerStreet1>C/O IROBOT CORPORATION</rptOwnerStreet1>
            <rptOwnerStreet2>8 CROSBY DRIVE</rptOwnerStreet2>
            <rptOwnerCity>BEDFORD</rptOwnerCity>
            <rptOwnerState>MA</rptOwnerState>
            <rptOwnerZipCode>01730</rptOwnerZipCode>
            <rptOwnerStateDescription></rptOwnerStateDescription>
        </reportingOwnerAddress>
        <reportingOwnerRelationship>
            <isDirector>false</isDirector>
            <isOfficer>true</isOfficer>
            <isTenPercentOwner>false</isTenPercentOwner>
            <isOther>false</isOther>
            <officerTitle>VP, Finance</officerTitle>
        </reportingOwnerRelationship>
    </reportingOwner>

    <aff10b5One>false</aff10b5One>

    <nonDerivativeTable>
        <nonDerivativeTransaction>
            <securityTitle>
                <value>Common Stock</value>
            </securityTitle>
            <transactionDate>
                <value>2024-02-21</value>
            </transactionDate>
            <transactionCoding>
                <transactionFormType>4</transactionFormType>
                <transactionCode>A</transactionCode>
                <equitySwapInvolved>false</equitySwapInvolved>
                <footnoteId id="F1"/>
            </transactionCoding>
            <transactionAmounts>
                <transactionShares>
                    <value>127</value>
                </transactionShares>
                <transactionPricePerShare>
                    <value>0</value>
                </transactionPricePerShare>
                <transactionAcquiredDisposedCode>
                    <value>A</value>
                </transactionAcquiredDisposedCode>
            </transactionAmounts>
            <postTransactionAmounts>
                <sharesOwnedFollowingTransaction>
                    <value>33106</value>
                </sharesOwnedFollowingTransaction>
            </postTransactionAmounts>
            <ownershipNature>
                <directOrIndirectOwnership>
                    <value>D</value>
                </directOrIndirectOwnership>
            </ownershipNature>
        </nonDerivativeTransaction>
        <nonDerivativeTransaction>
            <securityTitle>
                <value>Common Stock</value>
            </securityTitle>
            <transactionDate>
                <value>2024-03-06</value>
            </transactionDate>
            <transactionCoding>
                <transactionFormType>4</transactionFormType>
                <transactionCode>F</transactionCode>
                <equitySwapInvolved>false</equitySwapInvolved>
                <footnoteId id="F2"/>
            </transactionCoding>
            <transactionAmounts>
                <transactionShares>
                    <value>206</value>
                </transactionShares>
                <transactionPricePerShare>
                    <value>10.29</value>
                </transactionPricePerShare>
                <transactionAcquiredDisposedCode>
                    <value>D</value>
                </transactionAcquiredDisposedCode>
            </transactionAmounts>
            <postTransactionAmounts>
                <sharesOwnedFollowingTransaction>
                    <value>32900</value>
                </sharesOwnedFollowingTransaction>
            </postTransactionAmounts>
            <ownershipNature>
                <directOrIndirectOwnership>
                    <value>D</value>
                </directOrIndirectOwnership>
            </ownershipNature>
        </nonDerivativeTransaction>
    </nonDerivativeTable>

    <footnotes>
        <footnote id="F1">Represents shares awarded pursuant to Performance Share Units. The Compensation Committee authorized the issuance of the underlying shares based upon iRobot Corporation's achievement of pre-established performance criteria related to operating income goals for the three-year period ended December 31, 2023. These shares will vest on March 11, 2024.</footnote>
        <footnote id="F2">Consists of shares withheld by the Issuer to satisfy the tax withholding obligations of the Reporting Person upon vesting of Restricted Stock Units.</footnote>
    </footnotes>

    <ownerSignature>
        <signatureName>/s/ Glen D. Weinstein, Attorney-in-Fact</signatureName>
        <signatureDate>2024-03-08</signatureDate>
    </ownerSignature>
</ownershipDocument>
